Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

interactive strategy chart

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

    interactive strategy chart

    is there a way (or could there be a way in a coming version) to make a strategy chart interactive (instead of only using parameter settings) to make a change without losing real time data plots?

    for instance, I would imagine having an alert window pop up under a certain condition and then be able to input a value and have the cs use the value from that bar forward without replotting the whole chart...similar to an input button idea

    main issue here is being to change the chart without losing real time plots

    thanks
    Last edited by ATI user; 08-22-2008, 08:40 AM.

    #2
    Thanks for the suggestion!
    RayNinjaTrader Customer Service

    Comment


      #3
      come to think about it...you already have something like that don't you

      you can right click in an Indicator chart running Charttrader and select between a sell stop, buy stop and buy stoplimit

      perhaps we could right click in a strategy chart and choose from Input A, Input B, Input C... at which time it asks for the input...which could be a value or string

      for instance, I would like to be able to turn off autotrading without losing all the plotted data from prior trades....so I would input 'off' to Input A which my cs would monitor to adjust the autotrading variable

      even better, my cs would monitor Input B where I could input the number of ticks back that I want my cs to trail my stop during a trade

      maybe we could decide when declaring a variable in the Properties section of the cs code if we want that variable to be browsable from the right-click input dialog as well as from the Parameter Settings dialog

      something like that would be very powerful by adding a lot of flexibility to my cs code
      Last edited by ATI user; 08-23-2008, 01:53 PM.

      Comment


        #4
        Interesting. Thanks for sharing your thoughts.
        Josh P.NinjaTrader Customer Service

        Comment


          #5
          any chance that NT7 will have this capability?

          if not, or even if it will, could you please point me in the right direction re how access an external file from my strategy to pickup values without disturbing the chart plots?

          thanks

          Comment


            #6
            ATI user,

            There is no information about NT7 as of currently. We will make announcements when they become available.

            As to reading from external files, please see these reference samples: http://www.ninjatrader-support.com/v...ead.php?t=3476

            Josh P.NinjaTrader Customer Service

            Comment


              #7
              thanks Josh

              I will give those a try.

              Comment


                #8
                SampleStreamReader

                Josh

                In SampleStreamReader is the indicator supposed to create the txt file per this code?

                // This sets the path in which the text file will be created.
                private string path = Cbi.Core.UserDataDir.ToString() + "MyTestFile.txt";

                ...or am I...if me, where? I put a file in db/data and still got the error "File does not exist"

                Thanks.

                Comment


                  #9
                  ATI user,

                  That line does not create the file. That line is simply storing where the file is located at. The file location should be in My Documents\NinjaTrader 6.5\MyTestFile.txt and not in the db/data folder.
                  Josh P.NinjaTrader Customer Service

                  Comment


                    #10
                    Thanks Josh

                    It is reading the file fine and printing 0 0 0 0

                    How do I get data into the file? When I try to add data manaully it says it can not create the file...which is already created...does not make sense

                    I should mention that my intention is to manually change data in the file so my cs will pick it up and make a change without losing its plots.

                    Maybe I should have another indicator, streamwriter or other, that I can change a parameter setting in that would then write that to the file...which would then be read by streamreader???
                    Last edited by ATI user; 09-18-2008, 11:39 AM.

                    Comment


                      #11
                      Doh!

                      My cs picks up public variable values from several indicators all the time. Why not just have a dummy one that only holds the variables I want to change in my cs? Simple.

                      Will advise

                      Comment


                        #12
                        ATI user,

                        If you want to write to the file you will need to use StreamWriter. Reading from the file is done with StreamReader. Alternatively you can use the System.IO example one.
                        Josh P.NinjaTrader Customer Service

                        Comment


                          #13
                          Originally posted by ATI user View Post
                          Doh!

                          My cs picks up public variable values from several indicators all the time. Why not just have a dummy one that only holds the variables I want to change in my cs? Simple.

                          Will advise
                          Josh

                          There is no way to get the above to work is there?

                          Problem being the strategy feeds the variables to the indicator to then get back a result. I can not change an input parameter in the indicator in order to have it read by the strategy can I?

                          Bummer

                          Comment


                            #14
                            I am not exactly sure what you mean, but you can definitely expose variables in the indicator that can be read by the strategy. Please see this reference sample: http://www.ninjatrader-support.com/v...ead.php?t=4991
                            Josh P.NinjaTrader Customer Service

                            Comment


                              #15
                              Originally posted by NinjaTrader_Josh View Post
                              ATI user,

                              If you want to write to the file you will need to use StreamWriter. Reading from the file is done with StreamReader. Alternatively you can use the System.IO example one.
                              Ok. I just want a simple switch to turn on/off a variable in my strategy....without refreshing the chart. So I assume I need to have an indicator that writes a variable to a file (the indicator must be exclusive to the chart running my strategy so the chart does not refresh when I change the input to the writing indicator) and then have my strategy read the variable from the same file using streamreader code. Is that correct?

                              Is this what users are doing to input variables to a strategy without the plots refreshing?...or is there any method?

                              Thanks.

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                              0 responses
                              637 views
                              0 likes
                              Last Post Geovanny Suaza  
                              Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                              0 responses
                              366 views
                              1 like
                              Last Post Geovanny Suaza  
                              Started by Mindset, 02-09-2026, 11:44 AM
                              0 responses
                              107 views
                              0 likes
                              Last Post Mindset
                              by Mindset
                               
                              Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                              0 responses
                              569 views
                              1 like
                              Last Post Geovanny Suaza  
                              Started by RFrosty, 01-28-2026, 06:49 PM
                              0 responses
                              571 views
                              1 like
                              Last Post RFrosty
                              by RFrosty
                               
                              Working...
                              X