tests/assessment_tools/test_assessment_mse.R

#
# Copyright (c) 2017-2023, King Abdullah University of Science and Technology
# All rights reserved.
#
# ExaGeoStat-R is a software package provided by KAUST
#
#
#
# @file test-assessment-MSE.R
# ExaGeoStat R test example
#
# @version 1.2.0
#
# @author Faten Alamri & Sameh Abdulah
# @date 2021-01-31
library("exageostatr")                                           # Load ExaGeoStat-R lib.

x <- c(1:16)  
y<- c(5:20)                                           # Vector representing  number of true values.
ypre<- predict(lm(y ~ x))                             # Vector denoting values of number of y predicted values.

# Assessment function 
result = mean_square_error(y, ypre)

print(x)
print(y)
print(result)
ecrc/exageostatR documentation built on June 9, 2025, 9:06 p.m.