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

Read prices from a csv file and plot price zones on NT8 charts

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

    Read prices from a csv file and plot price zones on NT8 charts

    Hello,
    this is supposed to be a very easy and necessary task for any serious traders, I believe.

    I have a daily sequence of price levels generated by traders and written as a csv file.
    Is there a way to import them on the chart ? Can it be done on NT8?

    Thx
    Max

    #2
    Hello Max, thanks for your post.

    The StreamWriter class can read values from any file within your system. We have a full example here demonstrating how to use this class in a NinjaScript object:

    https://ninjatrader.com/support/help..._propertie.htm

    Please let me know if you have any questions on this material.
    Chris L.NinjaTrader Customer Service

    Comment


      #3
      Hello Chris,
      thanks for your answer but that's not helping.

      your link is for importing OHLC chart price data to draw a chart.
      I'm trying to plot levels which would need to be drawn on a chart for specific days.
      The functionality would include settings like zone color and how frequently to reload the file, etc.
      I've paid 1k for this platform and.... what am I doing with it if I cannot perform such a simple task?

      EXAMPLE:
      very easy... below I have the following S&P levels, I want to create bands out of them for last Friday trading chart, can you create bands out of them?

      Thanks
      Max



      03/12/20 21

      3954,00 3959,75
      3942,00 3945,50
      3932,75 3937,25
      3925,25 3930,50
      3911,50 3922,25
      3903,00 3910,00
      3898,50 3901,75
      3890,00 3893,00
      3871,25 3876,00
      3854,75 3863,25
      3845,50 3849,75
      3829,00 3833,75
      3815,75 3819,25
      3797,25 3801,75
      3776,50 3781,50
      3755,25 3762,50
      3728,00 3733,00
      3716,75 3721,00
      3696,00 3704,75
      3684,75 3688,25
      3674,25 3677,00
      3664,25 3670,75
      3652,00 3655,00
      3637,00 3641,75
      3624,50 3628,00
      3595,50 3604,00
      3586,75 3593,25
      3579,25 3584,50





      Last edited by Lando Calrissian; 03-13-2021, 04:29 PM.

      Comment


        #4
        Originally posted by Lando Calrissian View Post
        Hello Chris,
        thanks for your answer but that's not helping.

        your link is for importing OHLC chart price data to draw a chart.
        I'm trying to plot levels which would need to be drawn on a chart for specific days.
        The functionality would include settings like zone color and how frequently to reload the file, etc.
        I've paid 1k for this platform and.... what am I doing with it if I cannot perform such a simple task?

        EXAMPLE:
        very easy... below I have the following S&P levels, I want to create bands out of them for last Friday trading chart, can you create bands out of them?

        Thanks
        Max



        03/12/20 21

        3954,00 3959,75
        3942,00 3945,50
        3932,75 3937,25
        3925,25 3930,50
        3911,50 3922,25
        3903,00 3910,00
        3898,50 3901,75
        3890,00 3893,00
        3871,25 3876,00
        3854,75 3863,25
        3845,50 3849,75
        3829,00 3833,75
        3815,75 3819,25
        3797,25 3801,75
        3776,50 3781,50
        3755,25 3762,50
        3728,00 3733,00
        3716,75 3721,00
        3696,00 3704,75
        3684,75 3688,25
        3674,25 3677,00
        3664,25 3670,75
        3652,00 3655,00
        3637,00 3641,75
        3624,50 3628,00
        3595,50 3604,00
        3586,75 3593,25
        3579,25 3584,50

        You can certainly draw these lines and fill the zones using a custom indicator, not a feature provided on NInjaTrader or any other platform. If you do a search, there are a few indicators floating around on Future.io and this forum that draw unlimited "constant horizontal lines". These indicators can be modified to read data from a .csv file, draw the lines, and fill the zones.

        Cheers!

        Comment


          #5
          Hello Max, thanks for your reply.

          The example I sent is demonstrating how to access data from a .txt file using the StreamReader class. I do not have an exact example of importing price level data and drawing objects from that data, a custom script would need to be created to import the price level data, then automatically draw. The price pairs will also need a timestamp associated with each pair, and it will depend on what kind of chart you are drawing these bands to e.g. if you are using a 1 minute chart, you can draw an object at each minute in the session, but if you are using a tick based chart the timestamps can be random throughout the timeline, so you would need to draw the object at the next closest time stamp if the saved time stamp does not exist. This indicator demonstrates drawing colored bands between price levels:
          https://ninjatraderecosystem.com/use...el-with-color/

          Best regards,
          -ChrisL

          The NinjaTrader Ecosystem website is for educational and informational purposes only and should not be considered a solicitation to buy or sell a futures contract or make any other type of investment decision. The add-ons listed on this website are not to be considered a recommendation and it is the reader's responsibility to evaluate any product, service, or company. NinjaTrader Ecosystem LLC is not responsible for the accuracy or content of any product, service or company linked to on this website.
          Chris L.NinjaTrader Customer Service

          Comment


            #6
            Lando Calrissian Did you found what you where looking for? im trying to find exactly the same.

            Would be most appreciated if you could give me some help,

            Thank you in advance

            Comment


              #7
              Madtrade Yes I did found a way here
              https://www.discotrading.com/Description/3026
              But it is not as straightforward as you might think, at least that how it was for me
              All the best
              Max

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by antcoster, Today, 11:26 AM
              0 responses
              2 views
              0 likes
              Last Post antcoster  
              Started by WalterSkinner, 02-07-2022, 09:22 AM
              23 responses
              122 views
              0 likes
              Last Post Lance El Camino  
              Started by cryfgg, Today, 11:15 AM
              1 response
              7 views
              0 likes
              Last Post NinjaTrader_Jesse  
              Started by trdninstyle, Yesterday, 09:32 AM
              27 responses
              169 views
              0 likes
              Last Post NinjaTrader_ChelseaB  
              Started by sambathraj, 09-26-2022, 07:28 PM
              2 responses
              57 views
              0 likes
              Last Post sambathraj  
              Working...
              X