I am able to export signals to csv by (ab)using custom backtester (see here How to convert boolean to string (in order to export it to csv)?). But the export only has signals that resulted in trades.
I am looking at result of Scan and would like to export this to csv. I know how to do this using Amibroker GUI. I would like to do this in some automated way not involving clicking in Amibroker user interface. Is there a way how to (create and) export Scan results (signals) to csv using AFL?
Here are the differences between the two exports:
- Export from Scan result window has all the signals:
Symbol,Trade,Date,Close TLT,Buy,30/07/2002, 81.5200 TLT,Sell,31/07/2002, 82.5300 TLT,Sell,01/08/2002, 83.0000 TLT,Sell,02/08/2002, 83.8500 TLT,Sell,05/08/2002, 84.2200 TLT,Sell,09/08/2002, 84.8800 TLT,Sell,12/08/2002, 85.4000 TLT,Sell,13/08/2002, 86.4500 TLT,Sell,14/08/2002, 86.7800 TLT,Sell,20/08/2002, 86.2700 TLT,Buy,22/08/2002, 85.0600 TLT,Sell,23/08/2002, 85.9000 TLT,Sell,26/08/2002, 85.9800 TLT,Buy,28/08/2002, 85.8700 ...
- Export generated from (ab)using custom backtester (How to convert boolean to string (in order to export it to csv)?) has much les signals:
DateTime,Symbol,Price,IsEntry,IsExit,IsLong,IsScale,Reason,Type 30/07/2002,TLT,81.52000,-1,0,-1,0,0,1 31/07/2002,TLT,82.53000,0,-1,-1,0,1,2 22/08/2002,TLT,85.06000,-1,0,-1,0,0,1 23/08/2002,TLT,85.90000,0,-1,-1,0,1,2 28/08/2002,TLT,85.87000,-1,0,-1,0,0,1 ...