List of lua built-in indicator

Moderator: admin

List of lua built-in indicator

Postby ilnefopas » Wed Nov 07, 2018 1:49 pm

Hi guys,

I am willing to build a custom indicator and I'd like to leverage the standard indicators already included in LUA....like EMA, MVA,BB,...
I've been through the whole LUA doc but I'm not able to find a list of all the LUA built in indicators.
Does this exist somewhere ?

Thanks.
ilnefopas
 
Posts: 26
Joined: Mon Dec 28, 2015 12:51 pm

Re: List of lua built-in indicator

Postby Apprentice » Wed Nov 07, 2018 4:14 pm

No, but u can get a list of instaled indicator/oscillators via this three flags.
core.FLAG_INDICATOR
core.FLAG_ONLYINDICATORS
core.FLAG_ONLYOSCILLATORS

function Init()
indicator.parameters:addString("INDICATOR", "Indicator", "", "");
indicator.parameters:setFlag("INDICATOR",core.FLAG_INDICATOR);
end
You can use this as example.
viewtopic.php?f=17&t=62211&hilit=generic
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 36341
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: List of lua built-in indicator

Postby ilnefopas » Thu Nov 08, 2018 8:58 am

Thanks for the hand.
Now I've got 2 more questions :

1) Take BB for instance, to reference the upper bol I know that we use BB.TL, for the lower BB.BL. I do not know where I got that from but I know it. Can we find somewhere the different possibilities that we can use for a given built-in indicator ? Alternatively where is the source code of standard indicators on a TSII install ?

2) Moving to strategies now. Let's say I've built my custom indicator and imported it into TS2. Now I'd like to use it in a strategy. My understanding is that I can point the standard indcators library with that command "dofile(core.app_path() .. "\\strategies\\standard\\include\\helper.lua")". Am I right ? And if so how can I point my custom indicator library in my strategy code (if such library exist) ?

Thanks.
ilnefopas
 
Posts: 26
Joined: Mon Dec 28, 2015 12:51 pm

Re: List of lua built-in indicator

Postby ilnefopas » Thu Nov 08, 2018 7:16 pm

Ok my bad...helper.lua has nothing to do with indicators.

Anyway, my 2 questions in previous post remain.

Basically what I ma trying to understand is how we can use a standard or custom indicator in a strategy.
When I say use I mean how can we manipulate it (see BB example in previous post) and is this documented somewhere.
And finally is there 1/several libraries that we need to specifiacally call through an include in a strategy code ?

Thanks if you can help.
ilnefopas
 
Posts: 26
Joined: Mon Dec 28, 2015 12:51 pm


Return to Indicator Development

Who is online

Users browsing this forum: No registered users and 8 guests