Vendor-specific import wrappers for index total return levels (net or gross).
Usage
msci(file, col_trans, benchmarks = NULL, var_name = NULL, ...)
spdj(file, col_trans, benchmarks = NULL, var_name = NULL, ...)
msci_tsv(file, index_id, benchmarks = NULL, var_name = NULL, ...)Arguments
- file
Filename of the file to import.
- col_trans
Named character vector (or list) mapping index identifiers to regular expressions used to select the corresponding columns in Excel files. The names become the imported column names in the stored time series; the values are matched against the Excel column headers. Passed to
read_timeseries_excel().- benchmarks
Optional benchmark mapping(s) to record in the fund-index map (for example, to map gross to net indices for tracking-difference plotting alongside funds).
- var_name
Storage key used in
session$storage. IfNULL,tolower(file)is used.- ...
Arguments passed on to
store_timeseriesoverwriteLogical scalar. If
TRUE, recompute and replace any existing cached value, regardless offundsr.reload.postprocessFunction applied to the computed value before caching. Only used when the value is (re)computed (i.e. not applied when a cached value is reused). Defaults to
base::identity().sessionOptional
fundsr_sessionobject. Defaults to the package default session whenNULL.
- index_id
Index identifier used as the imported column name for text files containing a single index.
Value
Invisibly returns NULL. Data are stored via store_timeseries().
Details
Wrappers around store_timeseries() and either
read_timeseries_excel() or read_timeseries() for importing index files.
