Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

PS Landis formula from AFL to NT8

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    PS Landis formula from AFL to NT8

    I'm new in using NT 8 coming from Amibroker. I coded the below AFL formula by summing multiple stochastic periods, and add an EMA line with it:

    A= ((StochK(8,3)*.05)+(Stochk(89,21)*.43)+(Stochk(55, 13) *.26)+(Stochk(34,8)*.16)+(Stochk(21,5)*.1));
    EM= EMA(A,14);
    U= 80;
    M=40;
    D = 10;

    Plot(A,"Landis",colorWhite);
    Plot(EM,"EMA",colorRed);
    Plot(U,"Max",colorred);
    Plot(M,"Mid",colorYellow);
    Plot(D,"Min",colorGreen);


    It is pretty simple to code this one on other platforms. However, it has been weeks for me trying to put this together in NT8, but no luck so far. It took me 2 hours to figure this formula in AFL when I was a beginner, but getting someone to help me code this in NT8 will make a huge shortcut for me to do other formulas.

    #2
    Hello Albakmi2,

    Welcome to the NinjaTrader forums!

    In NinjaTrader plots are added with AddPlot().
    https://ninjatrader.com/support/help...t8/addplot.htm

    Values are set to the Values collection of plot series.
    https://ninjatrader.com/support/help...nt8/values.htm
    https://ninjatrader.com/support/help...t8/seriest.htm

    Have a look at the MACD or SMA indicator included with NinjaTrader in the NinjaScript Editor for an example of how setting a plot value in NinjaTrader works.

    An example of calling the Stochastics indicator can be found in the help guide.
    https://ninjatrader.com/support/help...tochastics.htm

    Below is a link to a forum post with helpful information about getting started with NinjaScript.
    https://ninjatrader.com/support/foru...040#post786040
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by wildleanketosale, Today, 03:49 AM
    0 responses
    1 view
    0 likes
    Last Post wildleanketosale  
    Started by wildleanketosale, Today, 03:48 AM
    0 responses
    2 views
    0 likes
    Last Post wildleanketosale  
    Started by hiltonvarai, Today, 03:10 AM
    0 responses
    1 view
    0 likes
    Last Post hiltonvarai  
    Started by afyuwi, Today, 02:33 AM
    0 responses
    2 views
    0 likes
    Last Post afyuwi
    by afyuwi
     
    Started by wushutrades, Today, 01:41 AM
    0 responses
    4 views
    0 likes
    Last Post wushutrades  
    Working...
    X