How to configure ema crossover strategy, please
Use Position keyword, and in that chose Series as Cross and Position as -1.
Then Click on Cross and select Series 1 as EMA and also Series 2 as EMA if you want to cross one EMA period with another EMA period.
Then set the parameters for each EMA by clicking on them.
Below is an example of EMA7 cross EMA14 on daily chart.
If you are building position when cross over happens then you can use runtime variable to store candle value
I created strategy with same code but in back testing it didn’t pick any trade. Please advise. Thank you
i want to store the candle high of that ema crossover, and only enter into trade when the candle high is broken…
whenever… post crossover any candle, not necessary that it should be the immediate next candle?
does it possible, can you show me with code example ?
@racha2068 if you can help
Sudash2000 - Can you share screen shot of your code?
Kpkp - I don’t think that’s possible with current features in tradetron. Other option is not suitable for you that I mentioned in different thread - wait till 11 AM.
( Position ( Cross ( EMA ( CLOSE ( Symbol ( Instrument Name ( ‘NFO,|Banknifty|,’ ) , ‘3m’, ‘All’ ) ) , ‘10’ ) , EMA ( CLOSE ( Symbol ( Instrument Name ( ‘NFO,|Banknifty|,’ ) , ‘3m’, ‘All’ ) ) , ‘20’ ) ) , ‘-1’ ) )
Code looks good. Instead of Cross keyword use Position (-1) and (-2) value of EMA to check cross over
Yes, i can try that. Thank you !
can you give example code screenshot…
@racha2068 @sudhash2000
is this what you are saying or different?
yes, that’s what the suggestion was from @racha2068 i believe. I haven’t BT it yet though as I’m working on some other code. Have you been able to BT it ?
i haven’t back tested it yet but i also want to achieve the entry condition only when the high or low of that crossover happens…
if you have any idea on how to do that, pls let me know…
The code that you pasted here is for that purpose only…right? Is it not working.
Kya aap runtime me kya Syntex dalna hai bata sakte ho please…