convert_to_matrices: Creates matrices of covariates.

Description Usage Arguments Value Examples

View source: R/mondrian_forest.R

Description

Internal function to separate a dataset into matrices of numeric and factor variables.

Usage

1

Arguments

X

Data (matrix or data frame).

Value

A list of matrices for numeric and factor variables (if any).

Examples

1
2
3
4
set.seed(1)
convert_to_matrices(data.frame(x1=rnorm(100),
                               x2=rbeta(100, 1, 2),
                               f1=sample(letters, 100, replace = TRUE)))

millerjoey/mondrianforest documentation built on May 25, 2019, 10:30 p.m.