Learn R Programming

topolow (version 1.0.0)

error_calculator_comparison: Calculate comprehensive error metrics between predicted and true distances

Description

Computes various error metrics including in-sample and out-of-sample errors, and Completeness statistics for model evaluation.

Usage

error_calculator_comparison(p_dist_mat, truth_matrix, input_matrix)

Value

A list containing:

report_df

A data.frame with detailed error metrics for each point-pair, including InSampleError, OutSampleError, and their percentage-based counterparts.

Completeness

A single numeric value representing the completeness statistic, which is the fraction of validation points for which a prediction could be made.

Arguments

p_dist_mat

Matrix of predicted distances

truth_matrix

Matrix of true distances

input_matrix

Matrix of input distances (may contain NAs and is used to find the NAs' pattern)

Details

Input requirements and constraints:

  • Matrices must have matching dimensions

  • Row and column names must be consistent between matrices

  • NAs are allowed and handled appropriately

  • Threshold indicators (< or >) in input matrix are processed correctly