Skip to content
Prev 12928 / 15274 Next

RFC: quantmod::getSymbols.MySQL

Hi Josh,

As you probably noticed, I updated getSymbols.FI() to use options a
couple weeks ago, but instead of using a single option that is a list,
I made a separate option for each function argument.  This allows two
things:  1) you can have different default values set for the "from"
argument (for example) of different getSymbols.*() methods. 2) It
doesn't change the old defaults.  i.e. getOption("someOption",
"2014-01-01") will return the value of the option if it is set, or
"2014-01-01" if not.

With your list structure, the default value has to be determined
inside the function, I suppose.

Here's the formal argument list for getSymbols.FI
function (Symbols, from = getOption("getSymbols.FI.from", "2010-01-01"),
    to = getOption("getSymbols.FI.to", Sys.Date()), ..., dir =
getOption("getSymbols.FI.dir",
        ""), return.class = getOption("getSymbols.FI.return.class",
        "xts"), extension = getOption("getSymbols.FI.extension",
        "rda"), split_method = getOption("getSymbols.FI.split_method",
        c("days", "common")), use_identifier =
getOption("getSymbols.FI.use_identifier",
        NA), date_format = getOption("getSymbols.FI.date_format"),
    verbose = getOption("getSymbols.FI.verbose", TRUE), days_to_omit =
getOption("getSymbols.FI.days_to_omit",
        c("Saturday", "Sunday")), indexTZ = getOption("getSymbols.FI.indexTZ",
        NA))


Garrett
On Wed, Oct 29, 2014 at 7:25 AM, Joshua Ulrich <josh.m.ulrich at gmail.com> wrote: