WaveThresh Help

ssq


Compute sum of squares difference between two vectors

DESCRIPTION

Computes the sum of the squared differences between two vectors.

USAGE

ssq(u,v)

REQUIRED ARGUMENTS

u
One of the vectors
v
The other vector

OPTIONAL ARGUMENTS

None.

VALUE

The sum of the squared differences. If n is the length of each vector then \eqn{\sum_{i=1}^n (u_i - v_i)^2}.

SIDE EFFECTS

None

DETAILS

A simple computation of the sum of the squared differences between two vectors. Used by the rsswav function.

RELEASE

Version 3.2.3 Copyright Guy Nason

SEE ALSO

rsswav.

EXAMPLES

#
# Here are two test vectors
#
u <- 10:1
v <- 1:10
#
# Apply this function
#
ssq(u,v)
> ssq(u,v)
#[1] 330
#
# A silly little function really!