NexusFi: Find Your Edge


Home Menu

 





Export Data for NinjaTrader8


Discussion in NinjaTrader

Updated
    1. trending_up 2,866 views
    2. thumb_up 3 thanks given
    3. group 2 followers
    1. forum 3 posts
    2. attach_file 2 attachments




 
Search this Thread
  #1 (permalink)
123vit
Kiev, Ukraine
 
Posts: 2 since Jul 2011
Thanks Given: 0
Thanks Received: 1

Hi!
Can someone convert ExportData (export your data in different time frame to csv) from NinjaTrader7 to NinjaTrader8


Attached Files
Elite Membership required to download: ExportDatav338.zip
Reply With Quote

Can you help answer these questions
from other members on NexusFi?
Netherlands & Germany Surge as World Cup Field Narro …
Prediction Markets & Event Contracts
The June 15 Resolution Trap: Irans Agreed Text Still Pri …
Prediction Markets & Event Contracts
Iran Airspace Collapses 18 Points to 15.5% While Hormuz …
Prediction Markets & Event Contracts
Iran Fired a Missile at Israel Last Night. The $8M June …
Prediction Markets & Event Contracts
Thanks Mike. Godspeed.
The Elite Circle
 
Best Threads (Most Thanked)
in the last 7 days on NexusFi
NexusFi site changelog and issues/problem reporting
8 thanks
Darmok and Jalad at Tanagra
1 thanks
  #3 (permalink)
123vit
Kiev, Ukraine
 
Posts: 2 since Jul 2011
Thanks Given: 0
Thanks Received: 1


Indicator for exporting data from NT8 to txt.
Default path E:\Data\txt


Attached Files
Elite Membership required to download: AStream.zip
Reply With Quote
Thanked by:
  #4 (permalink)
futurenow
Earth planet
 
Posts: 53 since Feb 2017
Thanks Given: 42
Thanks Received: 14


123vit View Post
Indicator for exporting data from NT8 to txt.
Default path E:\Data\txt

Hello

I'm trying to make a small modification to " AStream.zip" in order to have “column headings” (column titles) to visualize easily what is each value of the exported file, what would be useful if you want to add some other indicator data for example.


I’m trying with some variations of the next but it doesn’t work:

 
Code
...
protected override void OnStateChange()
{
    sw = File.AppendText(path);  // Open the path for writing
    sw.WriteLine("date" + "open" + "high" + "low" + "close" + "volume");
    ...
    sw = File.AppendText(path);  // Open the path for writing
    sw.WriteLine(Time[0] + " " + Open[0] + " " + High[0] + " " + Low[0] + " " + Close[0] + " " + Volume[0]); // Append a new line to the file
    
    sw.Close(); // Close the file to allow future calls to access the file again.
}
...


I also tried placing the code line ‘sw = File.AppendText(path);’ in a separate section as:
 
Code
...
else if (State == State.DataLoaded)
{
   sw = File.AppendText(path);  // Open the path for writing
}
...

// And in this way it worked but only when loading the indicator to the chart 
// and then having to remove the indicator from the chart in order to get the 
// data written in the file, because if the indicator is not removed then the
// file keeps in 0KB (empty).
So basically I know how to write only the “column titles” in the file, and separately I see how to write the chart data in the file, but I’m unable to get both things at the same time in the way you just load the indicator and done, i.e. without to have to remove the indicator from the chart to get the data.


Could someone please add this extra feature to the indicator?


Thank you in advance!


Reply With Quote




Last Updated on May 30, 2022


© 2026 NexusFi®, s.a., All Rights Reserved.
Av Ricardo J. Alfaro, Century Tower, Panama City, Panama, Ph: +507 833-9432 (Panama and Intl), +1 888-312-3001 (USA and Canada)
All information is for educational use only and is not investment advice. There is a substantial risk of loss in trading commodity futures, stocks, options and foreign exchange products. Past performance is not indicative of future results.
About Us - Contact Us - Site Rules, Acceptable Use, and Terms and Conditions - Downloads - Top
no new posts