That's not code. Attach a complied version of your code. And tell us what does-not work on it.
birendorf:
I want to use a 15min MA and a 30 MA and do back testing but it doesnt work, this is my code
BigMA=iMA(NULL,PERIOD_M15, PerBig,0,0,0,0);
BigMAShort=iMA(NULL,PERIOD_M30, PerBigShort,0,0,0,0);
BigMA=iMA(NULL,PERIOD_M15, PerBig,0,0,0,0);
BigMAShort=iMA(NULL,PERIOD_M30, PerBigShort,0,0,0,0);
- The call is
double iMA(string symbol, int timeframe, int period, int ma_shift, int ma_method, int applied_price, int shift)
7 parameters. Your call 8 parameters - invalid call. - Write self documenting code, don't use just numbers
BigMA=iMA(NULL,PERIOD_M15, PerBig, MODE_SMA, PRICE_CLOSE, 0);
- Tester limitation You CAN NOT get bar zero data for other timeframes/pairs. Don't use a shift of zero.
and stop shouting
WHRoeder:
- The call is
7 parameters. Your call 8 parameters - invalid call.
- Write self documenting code, don't use just numbers
- Tester limitation You CAN NOT get bar zero data for other timeframes/pairs. Don't use a shift of zero.
and stop shouting
I do use 7 parameters not 8, however I changed it as you said, but it still doesnt work, im doing back testing with this
BigMA=iMA(NULL,PERIOD_M15,PerBig,0,0,PRICE_CLOSE,1); MA9=iMA(NULL,PERIOD_M15,Per9,0,Long_MA_MODE,Long_applied_price_to,shift);
and right after im doing with this MA and getting defferents results
BigMA=iMA(NULL,0,PerBig,0,0,0,0); MA9=iMA(NULL,0,Per9,0,Long_MA_MODE,Long_applied_price_to,shift);
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I want to use a 15min MA and a 30 MA and do back testing but it doesnt work, this is my code
BigMA=iMA(NULL,PERIOD_M15, PerBig,0,0,0,0);
BigMAShort=iMA(NULL,PERIOD_M30, PerBigShort,0,0,0,0);
Short_MA9 =iMA(NULL,PERIOD_M30, Short_Per9,0, Short_MA_MODE, S_appliedTo, shift_s);
MA9=iMA(NULL,PERIOD_M15, Per9,0, Long_MA_MODE, L_appliedTo, shift);
Thanks for your help