Indicator and Strategy Parameters

Section for discussions related to indicators, use of indicators, and building of trading stategies using indicators.

Moderator: admin

Re: Indicator and Strategy Parameters

Postby MrRiversideDude » Wed Apr 23, 2014 3:24 pm

I emailed you the code, indicator and strategy, yesterday. Let me know if you got it.

Thanks!!
MrRiversideDude
 
Posts: 87
Joined: Fri Feb 21, 2014 7:50 am

Re: Indicator and Strategy Parameters

Postby Apprentice » Thu Apr 24, 2014 2:33 am

Test.lua
(6.42 KiB) Downloaded 876 times

We can not guarantee that the "STRATEGY" paremeter will be always available.
If you choose the MACD for example.
In can only select, "MACD", "SIGNAL", "HISTOGRAM".

Here you are trying to retrieve Strategy parameter.
tmpparams:getString("Strategy"));
We can not guarantee that the "STRATEGY" paremeter will be always at this point.

Here you retrieve Strategy parameter in the traditional way.
Strategy = instance.parameters.Strategy;

U will have to use
tmpparams:setString("Strategy",Strategy);
before referencing Strategy parameter.
tmpparams:getString("Strategy"));
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Previous

Return to Discussions

Who is online

Users browsing this forum: No registered users and 9 guests