Is there a way to export historical data to a file for further analysis?
Rename
Right click on a chart, select copy price data. paste into excel.
There's also a TimeSeries.WriteToFile function that will write an ASCII formatted file to disk.
CODE:BarHistory also has a similar function, but it writes a WL binary file, which can only be read by the BarHistory read function. A third-party application would have to know how to read that binary file to read it in. I'm not sure if there's an option for BarHistory to write an ASCII formatted file (like TimeSeries has).
public override void Initialize(BarHistory bars) { RSI rsi = RSI.Series(bars.Close, 14); PlotIndicator(rsi); //Write RSI data to a file string fileName = System.IO.Path.Join(WLHost.Instance.DataFolder, "RSIData.txt"); rsi.WriteToFile(fileName); }
Thank you.
See finantic.Export extension for more advanced features like .xls files (Excel) or parquet files.
Your Response
Post
Edit Post
Login is required