GOF_correlation_tests {HyMETT}R Documentation

Calculates Kendall's Tau, Spearman's Rho, Pearson Correlation

Description

Calculates Kendall's Tau, Spearman's Rho, Pearson Correlation, and p-values as a wrapper to the stats::cor.test function. Output is tidy-style data.frame.

Usage

GOF_correlation_tests(mod, obs, na.rm = TRUE, ...)

Arguments

mod

'numeric' vector. Modeled or simulated values. Must be same length as obs.

obs

'numeric' vector. Observed or comparison values. Must be same length as mod.

na.rm

'boolean' TRUE or FALSE. Should NA values be removed before computing. If any NA values are present in mod or obs, the ith position from each will be removed before calculating. If NA values are present and na.rm = FALSE, then function will return NA. Default is TRUE

...

Further arguments to be passed to or from stats::cor.test.

Details

See stats::cor.test for more details and further arguments to be passed to or from methods. Defaults are used.

Value

A tibble (tibble::tibble) with test statistic values and p-values.

See Also

cor.test

Examples

GOF_correlation_tests(mod = example_mod$streamflow_cfs, obs = example_obs$streamflow_cfs)


[Package HyMETT version 1.1.2 Index]