Read in real world data from X and y.
rwd_dgp.Rd
Read in real world data from X and y.
Usage
rwd_dgp(
X,
y,
support = NULL,
data_split = FALSE,
train_prop = 0.5,
return_values = c("X", "y")
)
Arguments
- X
Data matrix or data frame.
- y
Response vector.
- support
Vector of feature indices in the true support of the DGP.
- data_split
Logical; if
TRUE
, splits data into training and test sets according totrain_prop
.- train_prop
Proportion of data in training set if
data_split = TRUE
.- return_values
Character vector indicating what objects to return in list. Elements in vector must be one of "X", "y", "support".
Value
A list of the named objects that were requested in
return_values
. See brief descriptions below.
- X
A
data.frame
.- y
A response vector of length
nrow(X)
.- support
A vector of feature indices indicating all features used in the true support of the DGP.
Note that if data_split = TRUE
and "X", "y"
are in return_values
, then the returned list also contains slots for
"Xtest" and "ytest".