download_data(
name = NA,
symbol = NA,
from = "1902-01-01",
to = Sys.Date(),
show_symbols = FALSE,
path
)
Arguments
name
A character, personal identifier for a stock, default NA.
symbol
A character, the stock's symbol, default NA.
from
A date, setting the lower data bound, default is "1902-01-01".
to
A date, setting the upper data bound, default is the current date Sys.date().
show_symbols
A boolean, determining whether all saved symbols should be printed, default FALSE.
path
A character, setting the data saving path.
Value
No return value. Downloaded data is saved as "name.csv" in the folder "path/data".
Details
symbol has to match the official symbol on https://finance.yahoo.com.
Once used stock symbols are saved in "stock_symbols.rds" in the folder "path/data".
Values for from earlier than its default value are set to the default value.