|
How do I limit position number from Strategy code? |
kostakis
|
Post subject: How do I limit position number from Strategy code? |
Post rating: 0
|
Posted: Fri 19 Sep, 2014, 20:03
|
|
User rating: 1
Joined: Wed 30 Jul, 2014, 14:33 Posts: 95 Location: Lithuania, Vilnius
|
My strategy (attached) opens a lot of positions simultaneously. When I tested my Strategy on Historical Tester everything was ok. It did not open more than 1 position simultaneously. However, when I put it on my DEMO account it opened a lot of both direction positions simultaneously. I have a DEMO account on JFOREX platform and I would like to test my Strategy there. Please tell me how could I limit position number from my code in case to have just one position opened simultaneously on my Demo account?
Attachments: |
RSIMACD2_KK.vfs [41.13 KiB]
Downloaded 133 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
|
amine_chourou
|
Post subject: Re: How do I limit position number from Strategy code? |
Post rating: 1
|
Posted: Mon 22 Sep, 2014, 09:25
|
|
Visual JForex expert at Dukascopy | |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Greetings,
Your strategy behaves exactly the same when tested in Visual JFroex Vs Jforex platform. I double checked couple of trades and they are opened/closed the same date & time based on your conditions. Also, the Margin Cut occurred at 4pm 16th of Sep when the strategy is tested over last week (strat @ Sep 15th).
|
|
|
|
|
kostakis
|
Post subject: Re: How do I limit position number from Strategy code? |
Post rating: 0
|
Posted: Mon 22 Sep, 2014, 10:36
|
|
User rating: 1
Joined: Wed 30 Jul, 2014, 14:33 Posts: 95 Location: Lithuania, Vilnius
|
Thank you for the prompt answer. I just want to make myself clear. It's extremely important for me to have not more than 1 position opened at the same time. In the other words I want to have the same thing as in Strategy contest Rules, i. e. the maximum amount of simultaneously opened positions is 1. When I put my Strategy on Historical test in VisualJForex platform and in JForex demo platform it works properly (it opens the other position after the previous position is closed). Problems occur when I put it on my DEMO account. Strategy begins to open a lot of both direction trades simultaneously. So, how can I limit amount of simultaneously opened positions to 1? Please provide me with the appropriate code.
Thanks in advance.
|
|
|
|
|
amine_chourou
|
Post subject: Re: How do I limit position number from Strategy code? |
Post rating: 1
|
Posted: Mon 22 Sep, 2014, 14:22
|
|
Visual JForex expert at Dukascopy | |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Hi, Quote: Problems occur when I put it on my DEMO account. Strategy begins to open a lot of both direction trades simultaneously.
Do you mean when you run your strategy in real-time ? (VS historical tester) .??
|
|
|
|
|
amine_chourou
|
Post subject: Re: How do I limit position number from Strategy code? |
Post rating: 0
|
Posted: Mon 22 Sep, 2014, 15:42
|
|
Visual JForex expert at Dukascopy | |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Hi,
Looks like the topic was locked as you said, but is unlocked now. I've went through your strategy and modified couple of items but nothing structural: I removed the temporary unused variables and built the strategy in a new draft. Please double check the attached strategy before launching it in the contest.
Thanks
Attachments: |
Test.vfs [31.53 KiB]
Downloaded 176 times
|
DISCLAIMER: Dukascopy Bank SA's waiver of responsability - Documents, data or information available on
this webpage may be posted by third parties without Dukascopy Bank SA being obliged to make any control
on their content. Anyone accessing this webpage and downloading or otherwise making use of any document,
data or information found on this webpage shall do it on his/her own risks without any recourse against
Dukascopy Bank SA in relation thereto or for any consequences arising to him/her or any third party from
the use and/or reliance on any document, data or information found on this webpage.
|
|
|
|
|
|
kostakis
|
Post subject: Re: How do I limit position number from Strategy code? |
Post rating: 0
|
Posted: Mon 22 Sep, 2014, 19:08
|
|
User rating: 1
Joined: Wed 30 Jul, 2014, 14:33 Posts: 95 Location: Lithuania, Vilnius
|
Hi,
I tested the Strategy on my DEMO account in real time mode. YES now it works properly. Thank you a lot for your great job. It was my absolute pleasure.
Kind regards, kostakis
|
|
|
|
|
|
Pages: [
1
]
|
|
|
|
|