Learn R Programming

fftab (version 0.1.0)

.correlation: Compute Normalized Correlation Between Two Signals

Description

Computes the normalized correlation between two signals based on their Fourier representations.

Usage

.correlation(a, b)

Value

A numeric value representing the normalized correlation between the two signals.

Arguments

a

A fftab object or signal representing the first input.

b

A fftab object or signal representing the second input.

Details

This function computes the cross-spectrum of two signals, removes the DC component, and calculates the real part of the cross-spectrum sum. The result is normalized using the variances of both signals.

Normalization ensures that the correlation value lies between -1 and 1.