spectacles (version 0.5-0)

postResampleSpectro: Calculates performance indictors across resamples

Description

Given two numeric vectors of data, the root mean squared error, the R-squared, the bias, the RPD, the RPIQ, the CCC and the standard error are calculated. For two factors, the overall agreement rate and Kappa are determined.

Usage

postResampleSpectro(pred, obs)
spectroSummary(data, lev = NULL, model = NULL)

Arguments

data

a data frame or matrix with columns obs and pred for the observed and predicted outcomes

lev

a character vector of factors levels for the response. In regression cases, this would be NULL.

model

a character string for the model name

pred

A vector of numeric data

obs

A vector of numeric data

Details

This function extends postResample in the caret package.

Examples

Run this code
# NOT RUN {
predicted <-  matrix(rnorm(50), ncol = 5)
observed <- rnorm(10)
apply(predicted, 2, postResampleSpectro, obs = observed)
# }

Run the code above in your browser using DataLab