# fourierscore: Calculation of the Fourier score In cycle: Significance of periodic expression pattern in time-series data

## Description

The function calculates fourier score for a chosen periodicity.

## Usage

 `1` ```fourierscore(eset,T,times=seq_len(ncol(eset))) ```

## Arguments

 `eset` object of the class “ExpressionSet” `T` length of chosen period `times` measurement times (with the index of the column as default)

## Details

The Fourier score can be used to detect periodic signals. The closer a gene's expression follows a (possibly shifted) cosine curve of period T, the larger is the Fourier score. Mathematical details can be found in the given reference. The function `fourierscore` calculates the Fourier scores for all features of an ExpressionSet object.

## Value

Fourier scores for all features (genes) of `eset`

## Note

Note that this function evaluates soley the `exprs` matrix and no information is used from the `phenoData`. In particular, the ordering of samples (arrays) is the same as the ordering of the columns in the `exprs` matrix. Also, replicated arrays in the `exprs` matrix are treated as independent i.e. they should be averagered prior to analysis or placed into different distinct “ExpressionSet” objects.

## Author(s)

Matthias E. Futschik (http://www.cbme.ualg.pt/mfutschik_cbme.html)

## References

Matthias E. Futschik and Hanspeter Herzel (2008) Are we overestimating the number of cell-cycling genes? The impact of background models on time series analysis, Bioinformatics, 24(8):1063-1069

## Examples

 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25``` ```# Data preprocessing if (interactive()){ set.seed(1) data(yeast) # loading the reduced CDC28 yeast set (from the Mfuzz package) yeast <- yeast[1:600,] # for illustration yeast <- filter.NA(yeast) # filters genes with more than 25% of the expression values missing yeast <- fill.NA(yeast) # for illustration only; rather use knn method for yeast <- standardise(yeast) T.yeast <- 85 # cell cycle period (t=85min) times.yeast <- pData(yeast)\$time # time of measurements F <- fourierscore(yeast,T = T.yeast, times= times.yeast) # calculates the Fourier scores for yeast genes # Plot highest scoring gene plot(times.yeast,exprs(yeast)[order(-F)[1],],type="o", xlab="Time",ylab="Expression", main=featureNames(yeast)[order(-F)[1]]) # Plot lowest scoring gene plot(times.yeast,exprs(yeast)[order(F)[1],],type="o", xlab="Time",ylab="Expression", main=featureNames(yeast)[order(F)[1]]) } ```

### Example output

```Loading required package: Mfuzz

Attaching package: 'BiocGenerics'

The following objects are masked from 'package:parallel':

clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
clusterExport, clusterMap, parApply, parCapply, parLapply,
parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from 'package:stats':

The following objects are masked from 'package:base':

Filter, Find, Map, Position, Reduce, anyDuplicated, append,
as.data.frame, cbind, colMeans, colSums, colnames, do.call,
duplicated, eval, evalq, get, grep, grepl, intersect, is.unsorted,
lapply, lengths, mapply, match, mget, order, paste, pmax, pmax.int,
pmin, pmin.int, rank, rbind, rowMeans, rowSums, rownames, sapply,
setdiff, sort, table, tapply, union, unique, unsplit, which,
which.max, which.min

Welcome to Bioconductor

Vignettes contain introductory material; view with
'browseVignettes()'. To cite Bioconductor, see
'citation("Biobase")', and for packages 'citation("pkgname")'.