Description Usage Arguments Value Author(s) References Examples
View source: R/construct_newdata.R
Construct a data.frame from which to predict model values.
1 2 3 4 5 6 7 8 | construct_newdata(
clean_DF_restricted,
x_pred_type = maeve_options("x_pred_type"),
x_pred_vec = maeve_options("x_pred_vec"),
x_pred_interior_grid = maeve_options("x_pred_interior_grid"),
x_pred_spacing = maeve_options("x_pred_spacing"),
include_newdata_ID = maeve_options("include_newdata_ID")
)
|
clean_DF_restricted |
data frame with data restricted to those used in fitting the models. Most often set to 'clean_DF_restricted' data.frame returned from maeve::model_study(). |
x_pred_type |
character. See ?maeve_options(). |
x_pred_vec |
numeric vector. See ?maeve_options(). |
x_pred_interior_grid |
logical. See ?maeve_options(). |
x_pred_spacing |
numeric. See ?maeve_options(). |
include_newdata_ID |
logical. See ?maeve_options(). |
An R data.frame
Bill Forrest <forrest@gene.com>
Bill Forrest forrest@gene.com
1 2 3 4 5 6 7 8 9 10 | require( magrittr ) # want pipe operator "%>%"
##
vismo21 <-
vismodegib %>%
dplyr::filter( DAY_OF_STUDY <= 21 ) %>%
dplyr::rename( group = group_name, ID = animalID, x = DAY_OF_STUDY ) # internal names
## pass this to the construct_newdata() function.
vismo21_grid <-
vismo21 %>% # make, e.g., an even grid with one-day resolution:
maeve:::construct_newdata( x_pred_type = 'grid', x_pred_spacing = 1 )
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.