store_regression: Store results from ranger regression training and prediction.

Description Usage Arguments Value

View source: R/ranger_regression.r

Description

This function extracts information from the ranger objects generated by training or prediction and stores them in a data.frame. It compares the pre- dicted values in training and prediction to their true values and calculates various measures to describe the difference. 'Rsquared_all' refers to R2 calcu- lated on all samples instead of only out-of-bag samples in 'Rsquared'. This is only relevant for training, as there is no out-of-bag in prediction.

Usage

1
2
3
4
5
6
7
store_regression(
  trained_rf,
  predicted_rf = NULL,
  step,
  training_data,
  test_data = NULL
)

Arguments

trained_rf

the ranger object generated by training with 'ranger()'

predicted_rf

the ranger object generated by prediction with 'predict()', (default: 'NULL')

step

character declaring whether 'training' or 'prediction' occurs

training_data

data frame the ranger object was trained with

test_data

data frame the ranger object used for prediction

Value

A data frame with one row per ranger run and class


RJ333/phyloseq2ML documentation built on June 2, 2020, 9:25 p.m.