Using Aux1 and Aux2 to store symbol specfic values

I see that in addition to price and volume arrays associated with each symbol there are Aux1 and Aux2 arrays. As I understand it additional information can be downloaded and stored in these arrays when data is being imported to Amibroker.

My question is can they be used to store data from within an AFL program and have that data saved along with the other symbol specific arrays to the local disk based database?

It would be an alternative to creating static variable arrays that would exist in memory for each symbol. Symbol specific array data could be stored for a large number of symbols and retrieved on a per symbol basis only as needed along with the price and volume data.

Import csv files from AFL - AFL Programming - AmiBroker Community Forum

It has been attempted here. I can't say whether its optimal or the best practice.
Using Data Plugins can also wipe it out etc

Thanks for the reply, but importing from an external source is not what I was wanting.

I want to know if AFL code can calculate a value (like an IBD RS for all symbols) or actual buy and sell price levels and store that in Aux1 and Aux2 for each symbol and have it saved as part of the disk based database so it is available later without the overhead of having to calculate it again. Might look something like -------

Aux1 = RS();

Take a look at the AddToComposite() function.

1 Like

Thanks for the suggestion. Looks interesting, but I wonder if the values placed in Aux1 or Aux2 get saved to disk or are just saved temporarily in memory.

They are saved to disk

1 Like

This topic was automatically closed 100 days after the last reply. New replies are no longer allowed.