powered by
This function reads in asset data stored in .csv format and returns a time-series object of the asset data.
asset_loader(data_path, assets, price_col)
An xts object with asset data.
The path to the directory containing the .csv files.
A vector of asset names to be loaded.
The name of the price column to be selected (e.g. Open, Close, Low, High).
asset_loader(system.file("extdata", package = "StockDistFit"), c("AAPL", "TSLA"), "Close")
Run the code above in your browser using DataLab