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

Indicator plots 3 decimals only...

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

    Indicator plots 3 decimals only...

    The attached MomDivergence indicator has 3 plots, with one as a High/Low plot that is supposed to show the bar's High or Low when the indicator plots divergence. In the code, I am assigning the value to the plot by saying (these two lines of code are nestled into the buy and sell functions:
    Values[2].Set(int barsback, Low[int barsback]);
    or
    Values[1].Set(int barsback, High[int barsback]);

    But the problem is, in the Data Box it only shows 3 decimal places. This works fine for the JPY pairs, but problem for the other pairs.

    I tried to find in the indicator's code where it was declaring or limiting or rounding down to three decimals. But I could not find anything.

    I appreciate help on what I need to do.

    -Stearno

    More Details about my settings:
    • I am using NT7 on FXCM Demo Account (NT7 Type is SimulationOnly). It is version 7.0.1000.25
    • In Instrument Manager, @GBPUSD is set to a Tick Size of 0.0001. @EURJPY is set to 0.01.
    • I checked "Tools: Data:Quote currencies (FX) in:" and it is set to Pips. I tried changing it, but same result.
    Attached Files

    #2
    Stearno,

    Thank you for your post.

    You will want to override the FormatPriceMarker() to the number of decimals you are looking for
    http://www.ninjatrader.com/support/h...ricemarker.htm
    Cal H.NinjaTrader Customer Service

    Comment


      #3
      Thanks. That worked.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Radano, 06-10-2021, 01:40 AM
      19 responses
      605 views
      0 likes
      Last Post Radano
      by Radano
       
      Started by KenneGaray, Today, 03:48 AM
      0 responses
      4 views
      0 likes
      Last Post KenneGaray  
      Started by thanajo, 05-04-2021, 02:11 AM
      4 responses
      470 views
      0 likes
      Last Post tradingnasdaqprueba  
      Started by aa731, Today, 02:54 AM
      0 responses
      5 views
      0 likes
      Last Post aa731
      by aa731
       
      Started by Christopher_R, Today, 12:29 AM
      0 responses
      11 views
      0 likes
      Last Post Christopher_R  
      Working...
      X