dpcoa {ade4}R Documentation

Double principal coordinate analysis

Description

Performs a double principal coordinate analysis

Usage

dpcoa (df, dis = NULL, scannf = TRUE, nf = 2, full = FALSE, tol = 1e-07)
## S3 method for class 'dpcoa':
plot(x, xax = 1, yax = 2, option = 1:4, csize = 2, ...)
## S3 method for class 'dpcoa':
print (x, ...)

Arguments

df a data frame with elements as rows, samples as columns and abundance or presence-absence as entries
dis an object of class dist containing the distances between the elements.
scannf a logical value indicating whether the eigenvalues bar plot should be displayed
nf if scannf is FALSE, an integer indicating the number of kept axes
full a logical value indicating whether all non null eigenvalues should be kept
tol a tolerance threshold for null eigenvalues (a value less than tol times the first one is considered as null)
x an object of class dpcoa
xax the column number for the x-axis
yax the column number for the y-axis
option the function plot.dpcoa produces four graphs, option allows us to choose only some of them
csize a size coefficient for symbols
... ... further arguments passed to or from other methods

Value

Returns a list of class dpcoa containing:
call call
nf a numeric value indicating the number of kept axes
w1 a numeric vector containing the weights of the elements
w2 a numeric vector containing the weights of the samples
eig a numeric vector with all the eigenvalues
RaoDiv a numeric vector containing diversities within samples
RaoDis an object of class dist containing the dissimilarities between samples
RaoDecodiv a data frame with the decomposition of the diversity
l1 a data frame with the coordinates of the elements
l2 a data frame with the coordinates of the samples
c1 a data frame with the scores of the principal axes of the elements

Author(s)

Daniel Chessel
Sandrine Pavoine pavoine@biomserv.univ-lyon1.fr
Anne B Dufour dufour@biomserv.univ-lyon1.fr

References

Pavoine, S., Dufour, A.B. and Chessel, D. (2004) From dissimilarities among species to dissimilarities among communities: a double principal coordinate analysis. Journal of Theoretical Biology, 228, 523–537.

Examples

data(humDNAm)
dpcoahum <- dpcoa(humDNAm$samples, sqrt(humDNAm$distances), scan = FALSE, nf = 2)
dpcoahum
plot(dpcoahum, csize = 1.5)
## Not run: 
data(ecomor)
dtaxo <- dist.taxo(ecomor$taxo)
dpcoaeco <- dpcoa(ecomor$habitat, dtaxo, scan = FALSE, nf = 2)
dpcoaeco
plot(dpcoaeco, csize = 1.5)
## End(Not run)

Worked out examples


> library(ade4)
> ### Name: dpcoa
> ### Title: Double principal coordinate analysis
> ### Aliases: dpcoa plot.dpcoa print.dpcoa
> ### Keywords: multivariate
> 
> ### ** Examples
> 
> data(humDNAm)
> dpcoahum <- dpcoa(humDNAm$samples, sqrt(humDNAm$distances), scan = FALSE, nf = 2)
> dpcoahum
double principal coordinate analysis
class: dpcoa
$call: dpcoa(df = humDNAm$samples, dis = sqrt(humDNAm$distances), scannf = FALSE, 
    nf = 2)

$nf: 2 axis-components saved
eigen values: 0.1018 0.01035 0.006281 0.005602 0.003179 ...
  vector  length mode    content                                  
1 $w1     56     numeric weights of species                       
2 $w2     10     numeric weights of communities                   
3 $eig    9      numeric eigen values                             
4 $RaoDiv 10     numeric diversity coefficients within communities

  dist    Size content                          
1 $RaoDis 10   dissimilarities among communities

  data.frame  nrow ncol content                                    
1 $RaoDecodiv 3    1    decomposition of diversity                 
2 $l1         56   2    coordinates of the species                 
3 $l2         10   2    coordinates of the species                 
4 $c1         34   2    scores of the principal axes of the species
> plot(dpcoahum, csize = 1.5)
> 
> data(ecomor)
> dtaxo <- dist.taxo(ecomor$taxo)
> dpcoaeco <- dpcoa(ecomor$habitat, dtaxo, scan = FALSE, nf = 2)
> dpcoaeco
double principal coordinate analysis
class: dpcoa
$call: dpcoa(df = ecomor$habitat, dis = dtaxo, scannf = FALSE, nf = 2)

$nf: 2 axis-components saved
eigen values: 0.06598 0.0305 0.02234 0.01903 0.01053 ...
  vector  length mode    content                                  
1 $w1     129    numeric weights of species                       
2 $w2     16     numeric weights of communities                   
3 $eig    15     numeric eigen values                             
4 $RaoDiv 16     numeric diversity coefficients within communities

  dist    Size content                          
1 $RaoDis 16   dissimilarities among communities

  data.frame  nrow ncol content                                    
1 $RaoDecodiv 3    1    decomposition of diversity                 
2 $l1         129  2    coordinates of the species                 
3 $l2         16   2    coordinates of the species                 
4 $c1         128  2    scores of the principal axes of the species
> plot(dpcoaeco, csize = 1.5)
> 
> 
> 
> 
> 

[Package ade4 Index]