Learn R Programming

CHNOSZ (version 0.9-6)

util.stat: Functions for Various Statistical Operations

Description

Calculate root mean square deviation (RMSD), coefficient of variation of the RMSD, Spearman's rank correlation coefficient, or correlation coefficient of a q-q plot.

Usage

qqr(a)
  spearman(a, b)
  rmsd(a, b)
  cvrmsd(a, b)
  lograt(a, b)

Arguments

a
numeric values.
b
numeric values.

Details

qqr returns the correlation coefficient of a quantile-quantile plot using the values given in y.

spearman calculates Spearman's rank correlation coefficient between a and b. rmsd and cvrmsd return the root mean square deviation and coefficient of variation of the RMSD, repsectively. The coefficient of variation is computed as the RMSD divided by the mean of the values in a

lograt calculates the difference between a and b (i.e. log10 of the ratio of activities b/a) where a is a list of single values and b is a list of values, any dimension.

See Also

These functions are among the target statistics available in revisit.

Examples

Run this code
a <- 1:9
  b <- a + 1
  spearman(a, b)       # 1
  spearman(a, rev(b))  # -1
  qqr(a)               # <1
  rmsd(a,a)            # 0
  rmsd(a,b)            # 1
  cvrmsd(a,b)          # 1/5

Run the code above in your browser using DataLab