Description Usage Arguments Value
View source: R/ffDataDownload.R
This function automatically downloads US-Research portfolios returns from the Kenneth R. French Data Library. The downloaded returns are saved then as a .csv-file in the chosen directory.
1 2 3 4 5 6 7 8 9 10 | USresearch_download(
base,
dir,
sub_path,
number_factors,
freq,
start,
end,
cleanNAs
)
|
base |
a character string, the main webpage address "http://mba.tuck.dartmouth.edu/pages/faculty/ken.french/ftp/". |
dir |
a character string, the directory for saving the data. The current working directory is set by default. |
sub_path |
a character string, the folder subpath, created by ffDataDownload. |
number_factors |
an integer, the number of factors for the USResearch portfolios. Possible values are 3 (default) and 5. |
freq |
a character string, the frequency of returns. Possible values are "m" for monthly (default) or "d" for daily. |
start |
a character string, start date for the download in the format "YYmm". Default value is 197501. |
end |
a character string, end date for the download in the format "YYmm". Default value is two months before Sys.Date() to insure availability. |
cleanNAs |
a logical, TRUE (default) replaces NAs with zoo::na.locf(). If FALSE, NAs are not cleaned. |
a .csv-file within the directory, defined in dir.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.