Yes, that's the idea. Remember you also need to clear your "latch" e.g. when you drop < 75 or rise > 25.
Why extern?
Gday: a D1 Stochastic OB/OS trading robot
- youcrazykids
- Trader
- Posts: 44
- Joined: Sat Nov 19, 2011 8:38 am
- Location: Northumberland, UK
Re: Gday: a D1 Stochastic OB/OS trading robot
Ah, yes, sorry, forgot to mention the latch-clearing stuff, he he 
The use of extern is because the values of those variables are retained after every scan/pass/execution of the code. It may not be the best way to do it, but it has always worked for me.
The use of extern is because the values of those variables are retained after every scan/pass/execution of the code. It may not be the best way to do it, but it has always worked for me.
-
Kenboi
- Trader
- Posts: 66
- Joined: Tue Apr 24, 2012 4:35 am
Re: Gday: a D1 Stochastic OB/OS trading robot
Hi fxozgirl,fxozgirl wrote:Hi Kenboi,Kenboi wrote: Thanks for your explanation on those settings. I had those options turned off and the EA just triggered 2 pairs of sell trades (EURJPY and EURAUD) as soon as the market opens. It looks to me that the EA opens the trade at the beginner of the daily candle where it sees a signal. But, is it a little bit late for an entry especially on EURAUD based on the stochastic indicator? Take a look at the pictures.
I'm glad the EA has finally taken some trades for you...
The EA waits until the close of the candle to see if the criteria for trading has been met. Looking at the euraud chart you posted, the candle before the trade was taken had not crossed below the 75 level, so no trade was taken.
You might find it helpful to draw another line on your stoch for the 75/25 levels...just for the visual.
Thank you for your tips and explanation. I will do what you said. Last night, my EURAUD close with -165 pips due to the high impact news I guess. I am thinking not to trade when there're high impact news like Bank Decision Rate, NFP, and FMOC. What advice can you offer? Also, does the lot size have to be divisible by 3? I had it on .10 and it gives me errors, but just changed it to .12. Thanks, again for your help.
-
Fx93
- Trader
- Posts: 83
- Joined: Mon Apr 09, 2012 6:32 pm
Re: Gday: a D1 Stochastic OB/OS trading robot
I finally got three trades opened: USD/CAD, AUD/USD, EUR/GBP on FXCM. I probably missed a few trades Sunday having the EA down.
Any longer term forward tests to share anyone?
Any longer term forward tests to share anyone?
Last edited by Fx93 on Wed May 02, 2012 2:27 am, edited 1 time in total.
-
kelisa
- Trader
- Posts: 188
- Joined: Sun Mar 04, 2012 6:51 am
Re: Gday: a D1 Stochastic OB/OS trading robot
I had a gbpchf open (Buy order)since May1, closed 1/3 already, and now still floatin...
I am running both Good and OK pairs.
I am running both Good and OK pairs.
If your strategy is working well, dont be GREEDY and change it!
-
Kenboi
- Trader
- Posts: 66
- Joined: Tue Apr 24, 2012 4:35 am
Re: Gday: a D1 Stochastic OB/OS trading robot
Did the EA close 1/3 of your gbpchf trade?kelisa wrote:I had a gbpchf open (Buy order)since May1, closed 1/3 already, and now still floatin...
I am running both Good and OK pairs.
-
kelisa
- Trader
- Posts: 188
- Joined: Sun Mar 04, 2012 6:51 am
Re: Gday: a D1 Stochastic OB/OS trading robot
Yes, it closed 1/3 or the trade (50pips), then today closed another 1/3. Since this pair is rallying up, my final 1/3 lot is still floating w positive. It then open a USDCAD BUY. Am watching this to cook for another few days..Kenboi wrote:Did the EA close 1/3 of your gbpchf trade?kelisa wrote:I had a gbpchf open (Buy order)since May1, closed 1/3 already, and now still floatin...
I am running both Good and OK pairs.
If your strategy is working well, dont be GREEDY and change it!
- fxozgirl
- Trader
- Posts: 1176
- Joined: Wed Nov 16, 2011 9:16 am
- Location: Melbourne, Australia
Re: Gday: a D1 Stochastic OB/OS trading robot
Kenboi wrote: Hi fxozgirl,
Thank you for your tips and explanation. I will do what you said. Last night, my EURAUD close with -165 pips due to the high impact news I guess. I am thinking not to trade when there're high impact news like Bank Decision Rate, NFP, and FMOC. What advice can you offer? Also, does the lot size have to be divisible by 3? I had it on .10 and it gives me errors, but just changed it to .12. Thanks, again for your help.
Yep, I had an audcad trade that was in profit before the RBA announced it's decision and went for a loss.
I'm kicking myself for not closing the trade as it was pretty obvious interest rates were going to be cut
and on that note, this strategy does not perform very well in extremely volatile markets, mainly because the stoch is a lagging indicator and we're trading the daily charts
-
kelisa
- Trader
- Posts: 188
- Joined: Sun Mar 04, 2012 6:51 am
Re: Gday: a D1 Stochastic OB/OS trading robot
Hi Fxozgirl,
Been reading your post on FF and now here. Thanks for contributing Gday here, and I think its a wonderful system.
Are you still running all available pairs with the EA?
Currently, I have UCAD running, and I think human intervention is needed to TP soon.
Been reading your post on FF and now here. Thanks for contributing Gday here, and I think its a wonderful system.
Are you still running all available pairs with the EA?
Currently, I have UCAD running, and I think human intervention is needed to TP soon.
If your strategy is working well, dont be GREEDY and change it!
-
MiTija
Re: Gday: a D1 Stochastic OB/OS trading robot
An excellent example of deterministic finite automation. Well Done.youcrazykids wrote:Hey there
For the ">80 then <75" sequence and vice versa, I use a "latch" (as I call it). It goes something like:
Hope this helpsCode: Select all
extern int OBLatch, OSLatch; if ( StochSignal > 80 ) OBLatch=1; if ( OBLatch==1 && StochSignal < 75 ) { do whatever... } if ( StochSignal < 20 ) OSLatch=1; if ( OSLatch==1 && StochSignal > 25 ) { do whatever... }
youcrazykids
--MiTija