swh:1:snp:3a44eb759780145deea094ac2a25c5049546a085
Raw File
Tip revision: 0cb67c5fe3386e44746c8148a7ecf4e10ee1a933 authored by Han Lin Shang on 29 November 2020, 05:20:02 UTC
version 6.0
Tip revision: 0cb67c5
rmse.R
rmse <- function(forecast, true)
{
    if (length(forecast) != length(true))
        stop("RMSE: the lengths of input vectors must be the same.")
    err = sqrt(mean((true - forecast)^2))
    return(round(err, 6))
}

back to top