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

Strategy do not buy

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

    #16
    Originally posted by NinjaTrader_Jesse View Post
    you are saying that in this specific case it is caused because the data is not available, is this correct?
    Its only my opinion, I'm not sure about this, but the chances are that.
    I tried to redownload but it's not helping, is it possible to download a data online and import it? If yes tell me where can I download it.
    Thanks

    Comment


      #17
      Hello kamix265,

      Thank you for the reply.

      You can check what data you actually have by using either the historical data manager or the playback controller. If you are in playback, you can right-click the controller and choose Show Available Data.

      After checking if the data is there or not that will help in knowing if that is related.

      You can also use Prints to verify the logic you created is working as expected. As you are able to see the problem on your end, it would be easiest for you to re-run the script in that situation with Prints or other debugging added to see what values the script is actually seeing. This could help identify a specific part of the logic as the cause in that test. It is possible that the script performs differently when testing in different modes so using prints may be important in finding the cause.

      As for downloading data, I can only suggest using your data provider or the NinjaTrader playback download tool. You are free to search for third party data sources but I am unaware of any that I could list here.

      I look forward to being of further assistance.
      JesseNinjaTrader Customer Service

      Comment


        #18
        Here is it, available data. There is much missing, too much. I used 3rd software for download but still not working as I want to.
        Attached Files

        Comment


          #19
          Hello kamix265,

          Is this an instrument that you can download data for through your data provider or using the playback download tool included with NinjaTrader? You have excluded the instrument so I am unable to try this on my own.

          The other option would be to have a live data connection and record the data for playback. This does require that you leave the chart for that instrument open for the entire session if you want to record the whole session in one segment.

          Regarding the third party tool, I cannot assist with third party data so you would need to contact that source if you find data is missing from the data the tool downloads.

          I look forward to being of further assistance.
          JesseNinjaTrader Customer Service

          Comment


            #20
            Is there any way to read value of the last trade? Exactly, all I need is smoething like label of StopLoss. For example "IsFirstTickOfBar" returns true or false if it has been executed, is it possible to make that with stop? Maybe you know an another way?
            I have tried Trade but it makes some issues. I thought to read the value of last trade and compare with te stoploss value but I'm not sure how.
            Thanks for all help.

            Comment


              #21
              Hello kamix265,

              I am not certain I fully understand what you are asking here. You can access the various orders you create and their values. Generally, you would do this by storing the orders you use as objects so you can later access them when you wanted. We have a sample that demonstrates using Order objects here:



              If this is not what you are asking, could you try to rephrase your question or provide a simple example?

              I look forward to being of further assistance.

              JesseNinjaTrader Customer Service

              Comment


                #22
                Hi,
                I saw that errors when i was testing strategy by playback?
                What does it exactly mean?
                Attached Files

                Comment


                  #23
                  Hello kamix265,

                  This error would mean exactly what it says, the OCO id was reused which is not something that can be done.

                  Can you tell me, how are you currently submitting the orders you are using? Can you provide an example of the syntax for the order entry and stops/targets you have used?

                  This message can happen if you are using order entry methods that take an OCO and have supplied a non-unique OCO id. If you are not manually supplying an OCO ID, I would need more context of what was done in the logic to better understand why the message may be generated.

                  I look forward to being of further assistance.

                  JesseNinjaTrader Customer Service

                  Comment


                    #24
                    Entries per direction - 5
                    Contracts variable - 10
                    Target 15
                    Stop 8
                    that's all you need
                    Attached Files

                    Comment


                      #25
                      Hello kamix265,

                      Thank you for providing the sample. I have been trying this throughout the morning on the NQ as pictured in your last post but have not been able to see this error yet.

                      Can you tell me, is there a specific date that this error occurs for you that you can recreate or is this happening randomly?

                      Could you provide more detail on the specifics of the test you are doing such as the start date, how long before you see the error and any other items you can note such as playback speed?

                      I look forward to being of further assistance.
                      JesseNinjaTrader Customer Service

                      Comment


                        #26
                        Originally posted by NinjaTrader_Jesse View Post
                        Hello kamix265,

                        you can note such as playback speed?
                        How does it matter?
                        I have i7-6700K, 32G RAM, so it should make no difference.

                        Comment


                          #27
                          Hello kamix265,

                          In this case, because I cannot reproduce the problem with what you have provided so far, the questions I had asked may make a difference in the result of the test. I had not asked for the computer CPU model or Ram, but the NinjaTrader specific settings and questions related to NinjaTrader would be relevant here.

                          For example, does this occur each time you cover a specific point in time or did this occur once? This would be a good starting point.
                          If this occurred one time, there is a good chance I will not be able to reproduce the problem and that would be a helpful detail. If you are otherwise able to see this happen over and over, there should be some combination of settings that I can also reproduce this but I would need more details.

                          The playback speed would be helpful in contrast to how long it takes before you see the error from the starting point I asked for. This is so I have some expectation on the overall test to understand when you are seeing the error. If I am unable to see the problem with the details you provide, I will need to either try to gather more details from you or wait until you have a more exact example that you can provide.



                          Please let me know if I may be of further assistance.
                          JesseNinjaTrader Customer Service

                          Comment

                          Latest Posts

                          Collapse

                          Topics Statistics Last Post
                          Started by algospoke, Yesterday, 06:40 PM
                          2 responses
                          20 views
                          0 likes
                          Last Post algospoke  
                          Started by ghoul, Today, 06:02 PM
                          3 responses
                          14 views
                          0 likes
                          Last Post NinjaTrader_Manfred  
                          Started by jeronymite, 04-12-2024, 04:26 PM
                          3 responses
                          45 views
                          0 likes
                          Last Post jeronymite  
                          Started by Barry Milan, Yesterday, 10:35 PM
                          7 responses
                          21 views
                          0 likes
                          Last Post NinjaTrader_Manfred  
                          Started by AttiM, 02-14-2024, 05:20 PM
                          10 responses
                          181 views
                          0 likes
                          Last Post jeronymite  
                          Working...
                          X