Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Problem with data diplayed on M6E chart

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

    Problem with data diplayed on M6E chart

    Hi. I tried to plot a tick linebreak chart for the M6E instrument for August this year but I noticed that the data from the 6th to the 8th is missing even though I try to download all the historical data for this period. Could you please tell me why the charts for these dates is not being plotted? Thanks.

    #2
    Hello mbesha,

    Who are you connected to? This is displayed by green on lower left corner of the Control Center window.

    What Contract Expiry have you selected? Example M6E 09-13

    (For a chart) what interval is selected? 1 Minute, 150 Tick...

    Happy to be of further assistance.
    JCNinjaTrader Customer Service

    Comment


      #3
      Thanks for your prompt reply. I am connected to CQG, the contract is M6E 09-13, the chart is type : line break , base period type : tick , base period value : 1 , line breaks : 15.

      Comment


        #4
        Hello mbesha,

        Thanks for information. I was able to see data for August 6th through the 8th for the M6E 09-13.

        Could you remove your cache data by following the steps below:

        * Close NinjaTrader
        * Go to (My) Documents -> NinjaTrader 7 -> db
        * Right click on the folder "cache" and select delete.
        * Open NinjaTrader
        * Connect to data provider
        * Reload chart data

        Let me know if you are able to see the missing data.
        JCNinjaTrader Customer Service

        Comment


          #5
          I still can't see some data

          Thanks for the feedback. I tried to follow your instructions but however I still saw that the data displayed on the chart jumps from the 7th of August to the 12th of August. The data for the trading days in-between are missing.

          Comment


            #6
            Hello,

            Please right click in the chart and select the 'Reload All Historical Data' option. Does this cause the chart to backfill normally?
            KyleNinjaTrader Customer Service

            Comment


              #7
              Data is now displaying

              Thanks for that tip. I can now view the data. Highly appreciated.

              Comment


                #8
                Additional question regarding indicator development

                Hi. I am trying to see how I can rework the code for the PriorDayOHLC indicator so that I can create my own custom indicator which displays OHLC for 2 or even 3 days prior to the current trading session. I tried having a look at the code but I am not sure exactly where I ought to tweak to achieve this. Could you please help me with this as my programming know-how is low? Thanks in advance.

                Comment


                  #9
                  Hello mbesha,

                  You can create a new indicator with the original code from another indicator by going to the Control Center -> Tools -> Edit NinjaScript -> Indicators. Then double left click on the indicator that you want to have the original code from for example the "PriorDayOHLC". It will then open up the source code for the indicator. Right click inside the window and select Save As. Type in a name of your choosing then press "Save". Press the "OK" button as NinjaTrader will automatically rename them for you. Now you have a new indicator based off the system indicator code that you can modify to do what you would like.

                  So if you would like to check for previous trading sessions you use the FirstBarOfSession to be able to count how many trading sessions back you would like to check for. Here is an example of how FirstBarOfSession can be used that you may view.
                  JCNinjaTrader Customer Service

                  Comment


                    #10
                    I tried but I am having trouble with the code

                    I tried tweaking the code for the PriorDayOHLC using the tip you gave me for FirstBarOfSession but when I tried running the indicator, I didn't get the desired results. Could you please advise me on what is wrong with my code? Thanks in advance.
                    Attached Files

                    Comment


                      #11
                      Hello mbesha,

                      This is because you are only checking when the count is equal to "2" once meaning that it is only going to run once when the values are 0. You may want to check your count value when it is checking all of the other conditions and then reset the variable when the condition is met when it is setting the "currentDate" variable.

                      Let me know how the changes go.
                      JCNinjaTrader Customer Service

                      Comment


                        #12
                        Hello mbesha,

                        I forgot to mention that you may also want to start "count" at 0.
                        JCNinjaTrader Customer Service

                        Comment


                          #13
                          Still doesn't work properly

                          Thanks for the feedback. i tried starting from count = 0 but still there was a problem with how the indicator worked.

                          Comment


                            #14
                            Hello mbesha,

                            Did you also change when you are checking for count? For example inside of the same date check:

                            Code:
                            f (currentDate != Bars.GetTradingDayFromLocal(Time[0]) && /*changed*/ count >= 2 /*changed*/ || currentOpen == 0)
                            JCNinjaTrader Customer Service

                            Comment


                              #15
                              Indicator now plots well but there is still a problem

                              Upon checking the values of the indicator, I noticed that they are the same as PriorDayOHLC values instead of showing the values two days ago. I have attached my latest code for reference.
                              Attached Files

                              Comment

                              Latest Posts

                              Collapse

                              Topics Statistics Last Post
                              Started by DanielSanMartin, Yesterday, 02:37 PM
                              2 responses
                              12 views
                              0 likes
                              Last Post DanielSanMartin  
                              Started by DJ888, 04-16-2024, 06:09 PM
                              4 responses
                              12 views
                              0 likes
                              Last Post DJ888
                              by DJ888
                               
                              Started by terofs, Today, 04:18 PM
                              0 responses
                              11 views
                              0 likes
                              Last Post terofs
                              by terofs
                               
                              Started by nandhumca, Today, 03:41 PM
                              0 responses
                              7 views
                              0 likes
                              Last Post nandhumca  
                              Started by The_Sec, Today, 03:37 PM
                              0 responses
                              3 views
                              0 likes
                              Last Post The_Sec
                              by The_Sec
                               
                              Working...
                              X