Skip to contents

Named lists are matched by name; unnamed lists are matched by position. Each pair is checked before concatenation, so unequal split or fold lengths cannot silently shift observations. Missing pairs are removed together.

Usage

true_pred_data(x, y, group = NULL)

Arguments

x

Numeric vector, single-column matrix, or list: True observations.

y

Numeric vector, single-column matrix, or list: Predicted values.

group

Optional Atomic vector or single-column data frame: Groups for vector inputs.

Value

Data frame with true, predicted, and optional sample columns.

Examples

true_pred_data(1:3, c(1.1, 1.9, 3.2))
#>   true predicted
#> 1    1       1.1
#> 2    2       1.9
#> 3    3       3.2