Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Export to Excel

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

    Export to Excel

    I would like to analyze and map data through excel from my charts. Specifically, I would like to capture data from bars and compare for forensic and predictive analysis. It may be at bar close, price change or tick. It would include data from various indicators that I select and their respective settings. I assume this would be done through an Alert but I do not see anything that details something like this. can you lead me down this path? Thanks!

    Dolfan

    #2
    Hello Dolfan,

    Thank you for your post.

    While this would not be possible without custom programming, I was able to locate a custom strategy on our User App Share that achieves this.

    This strategy is publicly available on our NinjaTrader Ecosystem website:
    Here is a basic guideline of how to import NinjaScript add-ons in NinjaTrader 8:

    Note - To import NinjaScripts you will need the original .zip file.

    To Import:
    1. Download the NinjaScripts to your desktop, keep them in the compressed .zip file.
    2. From the Control Center window select the menu Tools > Import > NinjaScript Add-on...
    3. Select the downloaded .zip file
    4. NinjaTrader will then confirm if the import has been successful.

    Critical - Specifically for some NinjaScripts, it will prompt that you are running newer versions of @SMA, @EMA, etc. and ask if you want to replace, press 'No'

    Once installed, you may add the strategy to a chart by:
    • Right click your chart > Strategies... > Select the strategy from the 'Available' list on the left > Add > Properties > Enable > OK

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

    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.
    Zachary S.NinjaTrader Customer Service

    Comment


      #3
      I will take a look at this over the weekend. When you choose a print option that sends info about a bar to an output file, it tells you what the conditions of the bar are at the time of the print. This includes data from indicators used. Is this not feasible to send to an excel file?

      Dolfan

      Comment


        #4
        Hello Dolfan,

        Thank you for your reply.

        Which print option are you referring to? Feel free to include a screenshot if you feel that that would be helpful in explaining.
        Zachary S.NinjaTrader Customer Service

        Comment


          #5
          I'm not really sure what this strategy is doing for me. I also acknowledge that I am not very good at explaining what I am trying to do when I am trying something new. Using print may not be the correct term.

          Best case scenario would be if I could select a number of bars on a chart with select indicators and export that data to a spreadsheet for analysis. I would be happy if I could export one bar at a time. The data would be the same data one would see in a data box if open. I hope that is a little clearer.

          Dolfan

          Comment


            #6
            Hello Dolfan,

            Thank you for your reply.

            This strategy does exactly what you are outlining. Once applied to a chart and enabled, it will create a CSV output file within NinjaTrader's documents directory with the OHLC and volume values, as well as 2 user-defined indicator values. I've included an image of the output file and it's location within the NinjaTrader 8 documents folder.

            Zachary S.NinjaTrader Customer Service

            Comment


              #7
              Thanks Zach, this does work for the indicators MACD and EMA. Regarding those indicators, the MACD uses default settings of 12,26,9 but I have different settings that I like to use. Would I need to change them at the unlocked code level or can I change the settings in the strategy pane of the control center before activating? Same question goes for the EMA. Also regarding the EMA, how does it select the indicators? Can I simply change the reference from EMA to SMA in the coding and get the SMA data?

              That being said, I have other indicators that I would like to add for more analysis. Is it within your scope to guide me through this process? I feel like if I can get through one, I can figure the rest out for myself. Thanks once again.

              Dolfan

              Comment


                #8
                Hello Dolfan,

                Thank you for your reply.

                To confirm are you talking about making changes to an automated strategy? Or setting up indicators in your specific charts?

                Thank you I'll await your reply.
                Heath R.NinjaTrader Customer Service

                Comment


                  #9
                  I guess I would use this strategy to extract data from a chart where I would normally have indicators of my choosing. The strategy would have those indicators specified with the settings I would adjust accordingly. I am hoping that it is as simple as adding or duplicating lines of code where EMA or MACD currently exist, modifying to fit my indicators and compiling.

                  Dolfan

                  Comment


                    #10
                    Hello Dolfan,

                    Thank you for your reply.

                    The parameters for each indicator may be set from the 'Strategy' window when first enabling the strategy. If different values are required, I would suggest removing the strategy and re-adding it with the new indicator parameters. This will overwrite the current excel document.

                    With regard to changing the programming to allow for additional indicator plots, I would not have additional information on this matter but I will ask one of my colleagues on the NinjaScript Support teams to step in and see if they can provide some guidance.
                    Attached Files
                    Zachary S.NinjaTrader Customer Service

                    Comment


                      #11
                      Hello Dolfan, thanks for writing in.

                      Unfortunately, we are unable to modify the existing examples that we have available. This kind of script would be considered an intermediate to advanced level script, so it's not the best one to start out on if you are just starting out on NinjaScript.

                      All of our documentation for NinjaScript along with educational resources and reference samples can be found here for further reading:

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

                      Also, all of the default indicators and strategies that come with the platform are open source and can be viewed from the NinjaScript Editor.

                      Kind regards,
                      -ChrisL
                      Chris L.NinjaTrader Customer Service

                      Comment

                      Latest Posts

                      Collapse

                      Topics Statistics Last Post
                      Started by rdtdale, Today, 01:02 PM
                      1 response
                      3 views
                      0 likes
                      Last Post NinjaTrader_LuisH  
                      Started by alifarahani, Today, 09:40 AM
                      3 responses
                      15 views
                      0 likes
                      Last Post NinjaTrader_Jesse  
                      Started by RookieTrader, Today, 09:37 AM
                      4 responses
                      18 views
                      0 likes
                      Last Post RookieTrader  
                      Started by PaulMohn, Today, 12:36 PM
                      0 responses
                      9 views
                      0 likes
                      Last Post PaulMohn  
                      Started by love2code2trade, 04-17-2024, 01:45 PM
                      4 responses
                      41 views
                      0 likes
                      Last Post love2code2trade  
                      Working...
                      X