Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Market Analyzer column to Integer

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

    Market Analyzer column to Integer

    Hello,

    Is it possible to change a Market Analyzer column to integer, or to round the number or format decimal count?

    Thanks
    Ulises
    ulisesguerrero
    NinjaTrader Ecosystem Vendor - Thrifty Coders

    #2
    Hello ulisesguerrero,

    Thanks for writing in.

    This kind of formatting for the columns would not be available unless you created your own custom Market Analyzer column via NinjaScript and restricted the output values to what you would like.

    Please let me know if I may be of any further assistance.
    Alan S.NinjaTrader Customer Service

    Comment


      #3
      Thank you,

      I have tried to convert a double to int in my indicator output:

      temp = Convert.ToInt32(Math.Abs(Close[0]-Values[0][0])/(TickSize*10));
      Values[3][0] = temp;

      But the Market Analyzer still gives a double number: 1.0000

      Then I notice that within "Ninjascript generated code" it is still double, but when I change it to int, it automatically resets to double when I compile.

      What should I do?
      ulisesguerrero
      NinjaTrader Ecosystem Vendor - Thrifty Coders

      Comment


        #4
        Hello ulisesguerrero,

        The Values collection is a collection of double series that are used for plots.

        It will not be possible to change this.

        Below are public links to Value and Values.

        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          Ok, so how can I send an Integer to the Market Analyzer if not through the Values collection?
          ulisesguerrero
          NinjaTrader Ecosystem Vendor - Thrifty Coders

          Comment


            #6
            Hello ulisesguerrero,

            If you must be using an actual integer, you would need to make a MarketAnalyzerColumn script and set the CurrentText value from the <integer>.ToString() instead of using an indicator column.
            Below is a public link to the help guide.


            If you are just wanting 0 decimal places from a plot in an indicator you can use FormatPriceMarker() and set the ToString to use "N0".
            Below is a public link to the guide.
            Chelsea B.NinjaTrader Customer Service

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by arvidvanstaey, Today, 02:19 PM
            4 responses
            11 views
            0 likes
            Last Post arvidvanstaey  
            Started by samish18, 04-17-2024, 08:57 AM
            16 responses
            60 views
            0 likes
            Last Post samish18  
            Started by jordanq2, Today, 03:10 PM
            2 responses
            9 views
            0 likes
            Last Post jordanq2  
            Started by traderqz, Today, 12:06 AM
            10 responses
            18 views
            0 likes
            Last Post traderqz  
            Started by algospoke, 04-17-2024, 06:40 PM
            5 responses
            47 views
            0 likes
            Last Post NinjaTrader_Jesse  
            Working...
            X