avgp {GeneCycle}R Documentation

Average Periodogram for Multiple (Genetic) Time Series

Description

avgp calculates and plots the average periodogram as described in Wichert, Fokianos and Strimmer (2004).

Usage

avgp(x, title = deparse(substitute(x)), plot = TRUE, angular = FALSE, ...)

Arguments

x

multiple (genetic) time series data. Each column of this matrix corresponds to a separate variable/time series

title

name of the data set (default is the name of the data object)

plot

plot the average periodogram?

angular

convert frequencies to angular frequencies?

...

arguments passed to plot and to periodogram

Details

The average periodogram is simply the frequency-wise average of the spectral density (as estimated by the Fourier transform) over all times series. To calculate the average periodogram the function periodogram is used. See Wichert, Fokianos and Strimmer (2004) for more details.

Value

A list object with the following components:

freq

A vector with the discrete Fourier frequencies (see periodogram). If the option angular=TRUE then the output are angular frequencies (2*pi*f).

avg.spec

A vector with the average power spectral density at each frequency.

title

Name of the data set underlying the average periodogram.

The result is returned invisibly if plot is true.

Author(s)

Konstantinos Fokianos and Korbinian Strimmer (https://www.strimmerlab.org/).

References

Wichert, S., Fokianos, K., and Strimmer, K. (2004). Identifying periodically expressed transcripts in microarray time series data. Bioinformatics 20:5-20.

See Also

periodogram, spectrum.

Examples

# load GeneCycle library
library("GeneCycle")

# load data set
data(caulobacter)

# how many samples and how many genes?
dim(caulobacter)

# average periodogram
avgp.caulobacter <- avgp(caulobacter, "Caulobacter")
avgp.caulobacter

# just compute and don't plot 
avgp(caulobacter, "Caulobacter", plot=FALSE)

[Package GeneCycle version 1.1.5 Index]