procmod_frame.Rd 2.5 KB
Newer Older
Eric Coissac committed
1
% Generated by roxygen2: do not edit by hand
2
% Please edit documentation in R/procmod_frame.R
3 4 5
\name{procmod_frame}
\alias{procmod_frame}
\title{The procmod_frame data structure.}
Eric Coissac committed
6
\usage{
7
procmod_frame(..., row.names = NULL, check.rows = TRUE,
8 9 10 11
  reorder.rows = TRUE, contrasts.arg = NULL)
}
\arguments{
\item{...}{a set of objects to aggregate into a
12
\code{procmod_frame}. These objects can be
13 14 15 16 17
numeric matrices, or dist objects. Every objects
must have the same number of row.}

\item{row.names}{a character vector containing names associated
to each row.}
Eric Coissac committed
18

19 20
\item{check.rows}{a logical value. When set to \code{TRUE}, its
default value, the number of row of every elements of the
21
\code{procmod_frame} are tested for equality. Otherwise no
22
check is done.}
Eric Coissac committed
23

24 25
\item{reorder.rows}{a logical value. When set to \code{TRUE}, its
default value, every elements of the
26
\code{procmod_frame} are reordered according to the \code{row.names}
27 28 29 30 31 32 33 34 35
order. Otherwise nothing is done.}

\item{contrasts.arg}{A list, whose entries are values
(numeric matrices or character strings naming functions)
to be used as replacement values for the contrasts
replacement function and whose names are the names
of columns of data containing factors.}
}
\value{
36
a \code{procmod_frame} instance.
Eric Coissac committed
37 38
}
\description{
39 40
A \code{procmod_frame} can be considered as the analog of a
\code{data.frame} for vector data. In a \code{procmod_frame}
41 42 43 44 45
each element, equivalent to a column in a \code{data.frame}
is a numeric matrix or a distance matrix object (\code{dist}).
Every element must describe the same number of individuals.
Therefore every numeric matrix must have the same number of row
(\code{nrow}) and every distance matrix must have the same size
46
(\code{attr(d,"Size")}). A \code{procmod_frame} can simultaneously
47 48 49 50 51 52 53
contain both types of data, numeric and distance matrix.
}
\examples{
library(vegan)
data(bacteria)
data(eukaryotes)
data(soil)
Eric Coissac committed
54

55
dataset <- procmod_frame(euk = vegdist(decostand(eukaryotes,
56 57 58 59 60 61 62 63 64 65 66 67
                                                 method = "hellinger"),
                                       method = "euclidean"),
                         bac = vegdist(decostand(bacteria,
                                                 method = "hellinger"),
                                       method = "euclidean"),
                         soil = scale(soil,
                                      center = TRUE,
                                      scale  = TRUE))
length(dataset)
nrow(dataset)
ncol(dataset)
dataset$euk
Eric Coissac committed
68

Eric Coissac committed
69 70 71 72 73 74
}
\author{
Eric Coissac

Christelle Gonindard-Melodelima
}