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

Using a custom indicator

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

    #16
    imported post

    I assume you did this -

    tradingPrice = MyIndicator(1, 4, false, 80).Value[0];
    RayNinjaTrader Customer Service

    Comment


      #17
      imported post

      Well, no, I didn't, since that looks like another invocation. I thought after doing

      Add(MyIndicator(
      1, BidAskRatio, false, 80));

      that the values could be retrieved using

      tradingPrice = MyIndicator.Value[0];



      The good news is that trying this latest suggestion, doing

      tradingPrice = MyIndicator(1, 4, false, 80).Value[0];

      in the strategy works. Now my strategy code has both the Add of the indicator and the reference with inputs.


      The catch now is that the indicator isn't dispaying on the chart (though I am able to see the indicator values in the strategy). When I add the indicator by itself it does show on the chart, but when used from the strategy it does not.

      Thanks,

      Darryl

      Comment


        #18
        imported post

        Are there any error messages in the log? If not, could you email me the indicator?

        Ray
        RayNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by SaltyCoffee, Today, 01:13 AM
        0 responses
        4 views
        0 likes
        Last Post SaltyCoffee  
        Started by FishTrade, 05-13-2024, 11:11 PM
        3 responses
        13 views
        0 likes
        Last Post FishTrade  
        Started by Graci117, Yesterday, 09:02 PM
        1 response
        13 views
        0 likes
        Last Post NinjaTrader_Manfred  
        Started by ETFVoyageur, Yesterday, 07:55 PM
        0 responses
        9 views
        0 likes
        Last Post ETFVoyageur  
        Started by janio973, Yesterday, 07:24 PM
        1 response
        8 views
        0 likes
        Last Post NinjaTrader_Manfred  
        Working...
        X