Description Usage Arguments Details Value Author(s) See Also Examples
Download datasets from Kenneth French's Data Library.
1 2 3 |
dest.dir |
character: a path to a directory |
dataset |
a character string: the file name |
weighting |
a character string: |
frequency |
a character string: |
price.series |
logical: convert the returns series into prices series? |
na.rm |
logical: remove missing values in the calculation of price series? |
The function downloads data provided by Kenneth French at http://mba.tuck.dartmouth.edu/pages/faculty/ken.french/data_library.html.
The download file gets a date prefix (today in
format YYYYMMDD
) and is stored in directory
dest.dir
. Before any download is attempted,
the function checks whether a file with today's
prefix exist in dest.dir
; if yes, the file
used.
Missing values are usually coded as -99
or
similar values in the original data files. These
numeric values are replaced by NA
.
a data.frame
Enrico Schumann
1 2 3 4 5 6 7 | ## Not run:
archive.dir <- "~/Downloads/French"
if (!dir.exists(archive.dir))
dir.create(archive.dir)
French(archive.dir, "F-F_Research_Data_Factors_CSV.zip")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.