check_getFeatures_args: Check and validate arguments for getFeatures() and...

Description Usage Arguments Details Value Author(s)

Description

Check and validate arguments for getFeatures and ddply_getFeatures before they are used by those functions.

Usage

1
2
3
check_getFeatures_args(y, cont = NULL, disc = NULL, centerScale = TRUE,
  stats = c("min", "q1", "mean", "med", "q3", "max", "sd", "count"),
  fitQargs = NULL)

Arguments

y

Data frame, each row containing a vector of measurements for a particular point in time, with columns indicating the discrete and/or continuous measured variables (and possibly other descriptive variables). The data processed presuming the rows are orderd chronologically.

cont

Vector of integers or a character vector indicating the columns of x that correspond to continuous variables. These are the variables from which features will be extracted by fitting the moving regression model using fitQ.

disc

Vector of integers or character vector indicating the columns of x that correspond to variables that will be treated as discrete. These are the variables from which features will be extracted using discFeatures.

centerScale

Logical indicating whether the continuous variables (indicate by cont) should be centered and scaled by the global mean and standard deviation of that variable. By 'global', we mean all the values of a continuous variable, say x, in y are used to compute the mean and standard deviation. The resulting value for the continuous variable, x, is equivalent to y$x <- (y$x - mean(y$x)) / sd(y$x).

stats

This argument defines the summary statistics that will be calculated for each of the regression parameters. It can be a character vector of summary statistics, which are passed to summaryStats. Or the function object returned by summaryStats may be supplied.

fitQargs

Named list of arguments for fitQ. If NULL, the default arguments of fitQ are used. Any argument for fitQ may be included except y.

Details

This function exists so that multiple calls to getFeatures from ddply_getFeatures would not involve repeating the checks on essentially the same arguments.

Value

An object of class valid_getFeatures_args that can be passed to the first argument of getFeatures or ddply_getFeatures. It is a list with the same elements that were passed into the function: y, cont, disc, stats, and fitQ, with the exception that the continuous variables of y are now centered and scaled if centerScale = TRUE, and cont and disc are converted to the character column names (if integers were originally provided).

Author(s)

Landon Sego


pnnl/qFeature documentation built on May 25, 2019, 10:22 a.m.