rthomson

MA Crossover Strategy

2269 vizualizações
171
Allows you to backtest different SMA & EMA crossover strategies.
Remover dos scripts favoritos Adicionar aos scripts favoritos

Comentários

Hi!

Thanks for the good job. I still have an issue with my script, how do you do to have the signal one period after the cross and not right on the cross?

Thanks!
Resposta
@bishlar, it's a fault with Pinescript that on Strategies the entries are always a bar or two late.
Resposta
bishlar rthomson
@rthomson, thanks for the answer.
But i mean: i implemented a very simple crossover strategy, kind of MACD.
When i backtest my strategy, the issue is that the signal is given on the entry of the candle which makes the cross. But to be exact, the signal should be given on the close of the candle which makes the cross, or on the open of the next candle. And i dont mange how to do so. (it seems to be that way on your chart).

I hope i am clear enough :)

Resposta
@bishlar, that should be automatic if its an actual Strategy and not a Study.
Resposta
bishlar rthomson
@rthomson, oh right thanks!
I found my problem, i set an offset on the plot of my MAs but it isnt taken account for the crossover function. Is there a way to add an offset straight when using the sma function or in the crossover function?
Thanks for the help mate
Resposta
@bishlar, not as far as I know, but I have never tried
Resposta
u rock man !
Resposta
Início Rastreador de Fundamentos Rastreador Forex Rastreador de Criptomoedas Calendário Econômico Como Funciona Recursos gráficos Preços Indique um Amigo Regras da Casa Central de Ajuda Soluções para Sites & Corretoras Widgets Soluções em Gráficos Biblioteca de Gráficos Lightweight Blog & Notícias Twitter
Perfil Configurações de perfil Conta e cobrança Indique um Amigo Meus Tíquetes de Suporte Central de Ajuda Ideias Publicadas Seguidores Seguindo Mensagens Privadas Conversa Deslogar