• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Woodie Pivots in a strategy

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

    Woodie Pivots in a strategy

    I'm unable to get Woodie Pivot values into my strategy. Straight from the NJ8 documentation, it chokes during compile with the error
    "the best overload mthod for NinjaTrader.NinjaScript.Strategy.WoodiesPivots... has some invalid arguments"

    Then it complains about Argument 1. When I take that out, it compiles but the values are all 0.

    From the NJ8 documentation for Woodies Pivots usage

    // Prints the current pivot point value
    double value = WoodiesPivots(PivotRange.Daily, HLCCalculationMode.CalcFromIntradayData, 20).PP[0];
    Print("The current Woodies Pivots' pivot value is " + value);

    // Prints the current S2 pivot value
    double value = WoodiesPivots(PivotRange.Daily, HLCCalculationMode.CalcFromIntradayData, 20).S2[0];
    Print("The current Woodies Pivots' S2 pivot value is " + value);

    #2
    Hello mikeylikesit33,

    Thanks for your post and welcome to the forums!

    It appears the beta documentation has not been updated and we will correct that.

    In the meantime, in the Ninjatrader IDE, the intelliprompt shows only two parameters, one is HLCCalculationModeWoodie and the other is the integer length.

    Please try:
    Code:
    double test2 = WoodiesPivots (HLCCalculationModeWoodie.CalcFromIntradayData, 20).PP[0];
    Print("The current Woodies Pivots' PP pivot value is " + test2);
    
    double test3 = WoodiesPivots (HLCCalculationModeWoodie.CalcFromIntradayData, 20).S1[0];
    Print("The current Woodies Pivots' S1 pivot value is " + test3);
    
    double test4 = WoodiesPivots (HLCCalculationModeWoodie.CalcFromIntradayData, 20).R1[0];
    Print("The current Woodies Pivots' R1 pivot value is " + test4);
    
    double test5 = WoodiesPivots (HLCCalculationModeWoodie.CalcFromIntradayData, 20).S2[0];
    Print("The current Woodies Pivots' S2 pivot value is " + test5);
    
    double test6 = WoodiesPivots (HLCCalculationModeWoodie.CalcFromIntradayData, 20).R2[0];
    Print("The current Woodies Pivots' R2  pivot value is " + test6);
    Thanks for your participation in the beta program.
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Right, but as I said, when I take out the PivotRange... hence just using the two you indicate... the Print command shows all pivots as zero (0).

      So it seems they aren't working.

      Comment


        #4
        Hello mikeylikesit33,

        Thanks for your reply.

        I tested the example shown in my post on 1 minute data and it printed the Woodies pivots shown on the chart attached. Please note that the HLCCalculationMode is changed to HLCCalculationModeWoodie.
        Attached Files
        Paul H.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Austiner87, Yesterday, 11:52 PM
        0 responses
        1 view
        0 likes
        Last Post Austiner87  
        Started by daveace, Yesterday, 11:01 PM
        0 responses
        3 views
        0 likes
        Last Post daveace
        by daveace
         
        Started by Austiner87, Yesterday, 09:29 PM
        0 responses
        8 views
        0 likes
        Last Post Austiner87  
        Started by junkone, Yesterday, 08:58 PM
        0 responses
        7 views
        0 likes
        Last Post junkone
        by junkone
         
        Started by tradykat, Yesterday, 07:09 PM
        2 responses
        14 views
        0 likes
        Last Post tradykat  
        Working...
        X