model_matrix: Create data matrix for a model

Description Usage Arguments Value

View source: R/classification.R

Description

Extracts columns from data frame with names from model's mu field. Operates recursively, so it will work on a list of models

Usage

1

Arguments

model

a model (with field mu, a named vector) or a list of models that will be flattened until there's a field named mu.

data

a data frame with columns of the same names as the entries in model's mu

Value

a matrix with observations in rows and dimensions in columns.


kleinschmidt/phondisttools documentation built on May 20, 2019, 5:57 p.m.