Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

weekly pivots

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

    weekly pivots

    I have made a daily pivots indicator and now I'm trying to make weekly pivots using the same daily indicator.

    This isn't all the code but what i could post but this is the main part of it.

    PreHigh = PriorDayOHLC().PriorHigh[0];
    PreLow = PriorDayOHLC().PriorLow[
    0];
    PreClose = PriorDayOHLC().PriorClose[
    0];

    PP = (PreHigh + PreLow + PreClose) /
    3;
    R1 =
    2 * PP - PreLow;
    R2 = PP + (PreHigh - PreLow);
    R3 = R1 + (PreHigh - PreLow);
    S1 =
    2 * PP - PreHigh;
    S2 = PP - (PreHigh - PreLow);
    S3 = S1 - (PreHigh - PreLow);


    Plot0.Set(PP);
    Plot1.Set(R1);
    Plot2.Set(R2);
    Plot3.Set(R3);
    Plot4.Set(S1);
    Plot5.Set(S2);
    Plot6.Set(S3);


    #2
    Please take a look at our pivots indicator supplied with NinjaTrader per default, it includes an option for the weekly ones already (parameter PivotRangeType)
    BertrandNinjaTrader Customer Service

    Comment


      #3
      Pivots indicator

      The pivot indicator doesn't give the right weekly pivots i need that is why i need the code to be able go get the correct values.

      Comment


        #4
        Coby,

        The way NinjaTrader calculates pivots is discussed here: http://www.ninjatrader-support2.com/...ead.php?t=4676

        The values created are based off of whatever data you have on the chart.
        Josh P.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by traderqz, Today, 12:06 AM
        1 response
        2 views
        0 likes
        Last Post NinjaTrader_Gaby  
        Started by kujista, Today, 06:23 AM
        1 response
        2 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Started by Pattontje, Yesterday, 02:10 PM
        2 responses
        33 views
        0 likes
        Last Post Pattontje  
        Started by abdo22, Yesterday, 03:15 PM
        3 responses
        15 views
        0 likes
        Last Post NinjaTrader_Clayton  
        Started by f.saeidi, Yesterday, 02:09 PM
        3 responses
        20 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Working...
        X