Description Usage Arguments Details Value Author(s) References Examples
Function to compute a contingency periodogram for a univariate series of qualitative data
1 2 | Cperiodogram(x, T1 = 2, T2 = NULL, nperm = NULL, alpha = 0.05,
graph = TRUE)
|
x |
a qualitative variable ( |
T1 |
first period included in the calculations (default: T1 = 2) |
T2 |
last period included in the calculations (default: T2 = n/2) |
nperm |
Number of permutations for the chi-square test. For chi-square
tests using the chi- square distribution, use the default |
alpha |
significance level for computation of the confidence limits |
graph |
a logical indicating if a graph is requested, by default
|
The contingency periodogram of Legendre et al. (1981) identifies periodic components in qualitative data vectors. The vector may contain classes of a qualitative variable or the classes obtained by hierarchical clustering or partitioning of a multivariate data table. The method is also described in Legendre & Legendre (2012). The optional graph produced by the function shows the following information:
In red: the B statistics (information in common).
In blue: Confidence limits for B without correction.
In green: Bonferroni-corrected limits of the confidence intervals.
In black: Confidence limits with progressive Bonferroni correction.
A table with the statistics for the selected periods:
Wilks<e2><80><99> chi-square statistic (Wilks.chisq)
information in common (B),
degrees of freedom (df),
p-value (prob)
Confidence interval limits:
critical value of B without correction (B.crit),
critical value of B with Bonferroni correction based on the number of periods studied in the periodogram (B.crit.Bonf),
critical value of B with progressive Bonferroni correction (B.prog.Bonf).
Pierre Legendre pierre.legendre@umontreal.ca
Legendre, L., M. Fr<c3><a9>chette & P. Legendre. 1981. The contingency periodogram: a method of identifying rhythms in series on nonmetric ecological data. Journal of Ecology 69: 965-979.
Legendre, P. and Legendre, L. 2012. Numerical Ecology. 3rd English ed. Elsevier, Amsterdam
1 2 3 4 5 6 | # Data from the numerical example of Subsection 12.4.2 of Legendre and Legendre (2012).
test.vec <- c(1,1,2,3,3,2,1,2,3,2,1,1,2,3,3,1)
# Periodogram with tests using the chi-square distribution
res <- Cperiodogram(test.vec)
# Periodogram with permutation tests
res <- Cperiodogram(test.vec, nperm=2000, graph=FALSE)
|
Registered S3 methods overwritten by 'adegraphics':
method from
biplot.dudi ade4
kplot.foucart ade4
kplot.mcoa ade4
kplot.mfa ade4
kplot.pta ade4
kplot.sepan ade4
kplot.statis ade4
scatter.coa ade4
scatter.dudi ade4
scatter.nipals ade4
scatter.pco ade4
score.acm ade4
score.mix ade4
score.pca ade4
screeplot.dudi ade4
Registered S3 method overwritten by 'spdep':
method from
plot.mst ape
Registered S3 methods overwritten by 'adespatial':
method from
plot.multispati adegraphics
print.multispati ade4
summary.multispati ade4
Warning messages:
1: In chisq.test(tab, simulate.p.value = simulate, B = nperm) :
Chi-squared approximation may be incorrect
2: In chisq.test(tab, simulate.p.value = simulate, B = nperm) :
Chi-squared approximation may be incorrect
3: In chisq.test(tab, simulate.p.value = simulate, B = nperm) :
Chi-squared approximation may be incorrect
4: In chisq.test(tab, simulate.p.value = simulate, B = nperm) :
Chi-squared approximation may be incorrect
5: In chisq.test(tab, simulate.p.value = simulate, B = nperm) :
Chi-squared approximation may be incorrect
6: In chisq.test(tab, simulate.p.value = simulate, B = nperm) :
Chi-squared approximation may be incorrect
7: In chisq.test(tab, simulate.p.value = simulate, B = nperm) :
Chi-squared approximation may be incorrect
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.