init_stacker: Initialize stacker

Description Usage Arguments Value

Description

Creates a stacker governor containing the various information and data to run stacked generalization in IHME's MBG framework

Usage

1
2
3
4
init_stacker(..., inlist = T, data, indicator, indicator_family,
  covariate_layers, fe_equation, centre_scale = T, time_var = "year",
  time_scale = c(2000, 2005, 2010, 2015), weight_col = NULL,
  num_fold_cols = 1, num_folds = 1, cores = 1, sge_parameters = NULL)

Arguments

...

Initialized models. If blank, default versions of earth and gam are created.

inlist

logical. Are the models being passed through ... already in a list format?

data

data table. Dataset to be machine learned.

indicator

character vector. Name of the indicator (and by extension) the column name of the dependant variable

indicator_family

character vector. Designates the statistical family that should be modeled. Usually 'binomial' or 'gaussian'

covariate_layers

list of raster like objects. A named list of raster like objects of covariates

fe_equation

character vector of an equation. The equation specifying the fixed effects portion of the model. It should match with the names of covariate_layers.

centre_scale

logical. Determines whether the covariate values are centered/normalized before being returned. Binary variables are ignored.

time_var

character vector. Name of the column denoting the time (e.g. period or year) of a given data point

time_scale

numeric vector. List of years or times that the time var correlates to.

weight_col

character vector. Denotes the column (if applicable) in the dataset that specifies the data weights

num_fold_cols

numeric or character. Number of columns/interations for crossfold validation. if a character string, assume it refers to columns already existing in data. They will be renamed to sfold_#

num_folds

numeric. The number of folds the data is split on.

cores

numeric. The number of cores available for parallel computation

sge_parameters

object returned from init_sge. Provides sge parameters to govern submodel computation. If NULL, mclapply is used to run submodels instead

Value

Stacker governor object


dahcase/mbgstacking documentation built on May 20, 2019, 4:08 p.m.