build_design_matrix: Build the design matrix

Description Usage Arguments Value Examples

View source: R/design_matrix.R

Description

This function is called internally by other functions. It builds the design matrix for the models.

Usage

1
2
3
build_design_matrix(data, param_matrix, indices = NULL,
  empty_param_matrix_full = NULL, empty_design_matrix = NULL,
  print = TRUE)

Arguments

data

The dataset to be used

param_matrix

The matrix storing parameter values

indices

The list of indices computed by compute_indices

empty_param_matrix_full

The empty expanded or complete parameter matrix

empty_design_matrix

The empty design matrix

print

A boolean indicating whether or not to print information about potential issues

Value

The design matrix.

Examples

1
2
3
pmat <- build_param_matrix(param_values = c(0.1, 0.2), param_str = c("w1" = "s"))
dmat <- build_design_matrix(data = SurvEles_small, param_matrix = pmat)
table(dmat[, "w1"])

courtiol/SileR documentation built on May 16, 2020, 8:10 p.m.