rmsd: Root-mean-square deviation

Description Usage Arguments Value Author(s) Examples

View source: R/rmsd.R

Description

Calculate the root-mean-square deviation (rmsd) of two numeric vectors.

Usage

1
rmsd(v1, v2, na.rm = FALSE)

Arguments

v1

numeric vector for which to compute the rmsd with v2.

v2

numeric vector for which to compute the rmsd with v1; must have the same length as v1.

na.rm

a logical value indicating whether NA values should be stripped before the computation proceeds. Defaults to FALSE.

Value

The root-mean-square deviation of v1 and v2, or NA (for na.rm = FALSE) if any of their elements is NA.

Author(s)

Thomas Münch

Examples

1
2
3
v1 <- rnorm(1000)
v2 <- rnorm(1000)
rmsd(v1, v2)

EarthSystemDiagnostics/ecustools documentation built on Jan. 15, 2022, 5:22 p.m.