|
No Farm Payroll Strategy |
foreignexchange
|
Post subject: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Sun 04 Sep, 2016, 10:38
|
|
User rating: 0
Joined: Fri 19 Sep, 2014, 12:05 Posts: 61 Location: Italy, montopoli di sabina
|
Greeting, I would try to built a strategy for the NFP. The strategy should work only during the NFP period release and between 12:30:00 GMT and 12:30:15 GMT. The logic is that if the last tick ask is greater that the previous 10 min last ask candle high then a buy stop position is opened (with an opening price at last tick ask + 15 pips). Similarly if the last tick ask is lower than the previous 10 min last bid candle low then is opened a sell stop position (with an opening price at last tick bid - 15 pips). Can someone show where is the coding mistake ?
Attachments: |
NFP_pending_order_2.vfs [43.68 KiB]
Downloaded 157 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: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Mon 05 Sep, 2016, 10:38
|
|
Visual JForex expert at Dukascopy |  |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Hi,
Your conditions are too restrictive for the strategy to submit orders: the strategy should trade every month between the 1st and 7th AND only on Friday. Is this intentional ? Beside that, you are using time conditions including the seconds but you've linked your "Get time unit" to the candle start point which is filtering candle to get only 10 mn. So basically the Get time unit block will get the time stamp every 10 mn which wont help you. I've changed the way blocks are linked as per attached.
let me know if you have any questions
Cheers
Attachments: |
NFP_pending_order_3.vfs [43.62 KiB]
Downloaded 153 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.
|
|
|
|
|
 |
foreignexchange
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Mon 05 Sep, 2016, 12:11
|
|
User rating: 0
Joined: Fri 19 Sep, 2014, 12:05 Posts: 61 Location: Italy, montopoli di sabina
|
Greetings, Thanks for the reply reply and for the new version update. Yes, it is intentional that trade only the Friday because of the NFP statement and the strategy should be organized to have profit only for that release. I think I understand the tick question and your update but in backtesting it seems ti does not open trade even if looking the chart it should. Probably I have made a logic error. I would like to set the strategy with this indications: - Filter of NFP time release -One single trade (buy stop OR sell stop) -After the release (12:30:00 GMT) if the last tick ask is greater than the last candle high (10 min) open a buy stop position at 15 pips distance from the last candle high (similar in sell order)
Dunno if maybe there is a mistake in counting the last candle high because should be opened before the 12:30:00 GMT and so maybe the filter for the get time unit do not allow the information about the last candle high.
Thanks Amine
|
|
|
|
 |
amine_chourou
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Mon 05 Sep, 2016, 14:27
|
|
Visual JForex expert at Dukascopy |  |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Hi,
Indeed, my previous version was not including the full part that handling time conditions which is the reason why the strategy doesn't trade. Let me explain: With the previous example sthe strategy retreives the time correctly but it executes the condition vevery 10 mn (because these time conditions are plugged to oncandle) So in other words, when a new candle starts, seconds are usually equal to 0 where the strategy needs between 0 and 20. I've added a logical trigger with the variable "Go" as you can see. let me know if you need help to understand the way it works.
cheers
Attachments: |
NFP_pending_order_V3.vfs [45.87 KiB]
Downloaded 159 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.
|
|
|
|
|
 |
foreignexchange
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Mon 05 Sep, 2016, 17:42
|
|
User rating: 0
Joined: Fri 19 Sep, 2014, 12:05 Posts: 61 Location: Italy, montopoli di sabina
|
So the mistakes were : -the get time unit (tick unit instead candle because of one IF condition works on tick) - the link between on tick and on candle (information included in the assign variable)
I probably did not fully understand why the assign variable appear also after the opening at market (maybe because in that way it is assigned false to the variable GO and in this way do not open a new position).
Testing the strategy from 01/09/2016 to 02/09/2016 did not open a trade but with a chart analysis it should open a trade, so maybe there is also another indication to catch. Thank you very much for you suggestion Amine : )
|
|
|
|
 |
amine_chourou
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Tue 06 Sep, 2016, 08:14
|
|
Visual JForex expert at Dukascopy |  |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Hi,
Yes it is correct: The Go variable is set to false to avoid opening new position. The only condition that triggers Go to true is the time. Generally speaking, it's very practical way that once fully understood you'll use it in different ways as it open the doors to implement many ideas.
Looking again to your strategy, I think it is better to focus on tick method as it quite time sensitive (trading during 20 seconds on friday) SO I decided to change the method as per attached. I've also increased the check of open positions and pending position to avoid sending multiple orders thus find yourself with many positions afterwards.
Please have a look and let me know
Attachments: |
NFP_pending_order_V4.vfs [45.41 KiB]
Downloaded 170 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.
|
|
|
|
|
 |
foreignexchange
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Tue 06 Sep, 2016, 12:15
|
|
User rating: 0
Joined: Fri 19 Sep, 2014, 12:05 Posts: 61 Location: Italy, montopoli di sabina
|
Amine thank you so much for your kindly and professional work. The logic now it seems appear in agreement with the strategy and I understand that the assign variable could be very useful for programming strategy. If I would that both position in pending order can be opened but when one reach the TP the other have to be deleted what instruction has to be utilized ?
Thanks : )
|
|
|
|
 |
amine_chourou
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Wed 07 Sep, 2016, 11:10
|
|
Visual JForex expert at Dukascopy |  |
User rating: 288
Joined: Thu 18 Apr, 2013, 09:26 Posts: 1496 Location: Switzerland, Geneva
|
Hi,
The logical variable "Go" was used because I split the strategy flow into 2 one from tick and the other from candle. As you have seen, some conditions are plugged on tick method and the other form candle. So to make sure that the sequence of conditions are verified, meaning 1/ time conditions then 2/ price condition, I used this variable to have if 1/ is okay then Go--> True then the flow out of 2/ can be "released".
for your new condition, I suggest to implement your idea using Trade event start point. an example is attached.
Attachments: |
Example.vfs [28.88 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.
|
|
|
|
|
 |
foreignexchange
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Wed 07 Sep, 2016, 16:08
|
|
User rating: 0
Joined: Fri 19 Sep, 2014, 12:05 Posts: 61 Location: Italy, montopoli di sabina
|
|
|
|
 |
robertfxo
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Thu 15 Sep, 2016, 10:02
|
|
User rating: 0
Joined: Thu 15 Sep, 2016, 09:59 Posts: 2 Location: United Kingdom,
|
Heya, did you get a chance to test this already? If yes how did it go?
|
|
|
|
 |
foreignexchange
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Fri 23 Sep, 2016, 11:47
|
|
User rating: 0
Joined: Fri 19 Sep, 2014, 12:05 Posts: 61 Location: Italy, montopoli di sabina
|
Yes and with some update to the setting seems profitable Good trading
|
|
|
|
 |
foreignexchange
|
Post subject: Re: No Farm Payroll Strategy |
Post rating: 0
|
Posted: Fri 23 Sep, 2016, 14:55
|
|
User rating: 0
Joined: Fri 19 Sep, 2014, 12:05 Posts: 61 Location: Italy, montopoli di sabina
|
Good evening,
to test the strategy on specific macro release (FED interest rate) , I utilized a similar logic but do not understand why does not fill the pending order. Do you know if there are specific function to select some release ? (Something linked with the economic cal or similar)
|
|
|
|
 |
|
Pages: [
1
]
|
|
|
|
|