pvalrsr: Finds pvalue for testing periodicity using RSR.

Description Usage Arguments Details Value Author(s) References Examples

View source: R/pvalrsr.R

Description

It finds pvalue for tesing periodicity for any series using RSR.

Usage

1
pvalrsr(x,  t=1:length(x), nf=150, Numpq = 11)

Arguments

x

series to be tested for periodicity

t

vector of corresponding time points

nf

number of frequencies to enumerate

Numpq

Numebr of indices for interpolation in RSR

Details

A full RSR is integral part of the package. This was done using likelihood ratio statistic for simulated series from white noise process. For more information about the procedure, please see the first reference.

Value

pvalue

Author(s)

M. S. Islam

References

Islam, M.S. (2008). Peridocity, Change Detection and Prediction in Microarrays. Ph.D. Thesis, The University of Western Ontario.

MacKinnon, J. G. (2001). Computing numerical distribution functions in econometrics. In proceedings of High Performance Computing Systems and Applications, edited by Pollard, A., Mewhort, D. J. and Weaver, D. F. Springer US. Vol. 451, 455-471.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
# Non-Fourier frequency
z<-SimulateHReg(20, f=2.5/20, 1, 2)
pvalrsr(z)  # finding p-value using RSR

# For comparing with Fisher's g test
# library(GeneCycle)
# fisher.g.test(z) # Fisher's g test


# Fourier frequency
y<-SimulateHReg(20, f=2/20, 1, 2)
pvalrsr(y)  # finding p-value using RSR
# For comparing with Fisher's g test
# library(GeneCycle)
# fisher.g.test(z) # Fisher's g test

pRSR documentation built on May 2, 2019, 12:09 a.m.