@@ -27,7 +27,10 @@ caicStyleArgs(phy, data, names.col, warn.dropped=FALSE)
2727}
2828%- maybe also ' usage' for other objects documented here.
2929\arguments {
30- \item {data }{A data frame containing variables that can be attributed to the taxa at the tips of a phylogeny. }
30+ \item {data }{
31+ A data frame containing variables that can be attributed to the taxa at
32+ the tips of a phylogeny.
33+ }
3134 \item {phy }{A phylogeny (class ' phylo' ) to be matched to the data above. }
3235 \item {names.col }{The name of a column in the provided data frame that will be used to match data rows to phylogeny tips. }
3336 \item {vcv }{A logical value indicating whether to include a variance covariance array representing the phylogeny within the comparative dataset. }
@@ -40,23 +43,51 @@ caicStyleArgs(phy, data, names.col, warn.dropped=FALSE)
4043 \item {object }{An object of class ' comparative.data' . }
4144 \item {subset }{A logical expression indicating rows of data to keep : missing values are taken as false. }
4245 \item {select }{An expression , indicating columns to select from the data frame. }
43- \item {order }{One of ' cladewise' or ' pruningwise' . See \code {\link {reorder.phylo }}. }
46+ \item {order }{One of ' cladewise' or ' pruningwise' . See \code {\link [ ape ] {reorder.phylo }}. }
4447 \item {i ,j }{Indices specifying tips or data columns to extract. See details. }
4548 \item {... }{Further arguments to functions. }
4649}
4750
4851
4952\details {
50- The function matches rows in a data frame to tips on a phylogeny and ensures correct ordering of the data with respect to the tips. It also can add a variance covariance representation of the phylogeny. Mismatched rows and tips are removed and the taxon labels of these are stored in the ' dropped' slot of the ' comparative.data' object. The ' print' method displays a brief summary of the dataset contents and the names of the original ' phylo' and ' data.frame' objects. If any rows or tips were dropped , ' print' will also show a venn diagram of the data shared and dropped from each source. Node labels are preserved but must be unique - unlabelled nodes will be assigned numeric codes.
53+ The function matches rows in a data frame to tips on a phylogeny and ensures
54+ correct ordering of the data with respect to the tips. It also can add a
55+ variance covariance representation of the phylogeny. Mismatched rows and tips
56+ are removed and the taxon labels of these are stored in the ' dropped' slot of
57+ the ' comparative.data' object. The ' print' method displays a brief summary of
58+ the dataset contents and the names of the original ' phylo' and ' data.frame'
59+ objects. If any rows or tips were dropped , ' print' will also show a venn diagram
60+ of the data shared and dropped from each source. Node labels are preserved but
61+ must be unique - unlabelled nodes will be assigned numeric codes.
5162
52- The ' na.omit' and ' subset' methods provide simple ways to clean up and extract parts of the comparative dataset. In particular , ' subset' acts exclusively with the data component of the object and , like subset on a data frame , expects the subset argument to produce a logical vector of data rows to include. The ' reorder' method is use to restructure all the components with the ' comparative.data' object into either pruningwise or cladewise order. This uses code from the ' ape' library : see \code {\link {reorder.phylo }}.
63+ The ' na.omit' and ' subset' methods provide simple ways to clean up and extract
64+ parts of the comparative dataset. In particular , ' subset' acts exclusively with
65+ the data component of the object and , like subset on a data frame , expects the
66+ subset argument to produce a logical vector of data rows to include. The
67+ ' reorder' method is use to restructure all the components with the
68+ ' comparative.data' object into either pruningwise or cladewise order. This uses
69+ code from the ' ape' library : see \code {\link [ape ]{reorder.phylo }}.
5370
54- The ' [' method allows subsets to be taken of the data. There are no replace methods (' [<-' ). If only one index is specified (e.g. x [2 ]), then this is interpreted as extracting data columns from the object. Otherwise (e.g. x [2 ,], x [1 ,1 ]), the first index will specify tips to extract and the second index will specify columns. Indices for tips are permitted to be numeric , logical or character vectors or empty (missing ) or NULL . Numeric values are coerced to integer as by as.integer (and hence truncated towards zero ). Character vectors will be matched to the names of the object (or for matrices / arrays , the dimnames ): see ' Character indices' below for further details.
71+ The ' [' method allows subsets to be taken of the data. There are no replace
72+ methods (' [<-' ). If only one index is specified (e.g. x [2 ]), then this is
73+ interpreted as extracting data columns from the object. Otherwise (e.g. x [2 ,],
74+ x [1 ,1 ]), the first index will specify tips to extract and the second index will
75+ specify columns. Indices for tips are permitted to be numeric , logical or
76+ character vectors or empty (missing ) or NULL . Numeric values are coerced to
77+ integer as by as.integer (and hence truncated towards zero ). Character vectors
78+ will be matched to the names of the object (or for matrices / arrays , the
79+ dimnames ): see ' Character indices' below for further details.
5580
56- The function ' caicStyleArgs' handles turning ' phy' , ' data' and ' names.col' arguments into a ' comparative.data' object when they are provided separately to a function . This argument structure was used in older versions of many functions.
81+ The function ' caicStyleArgs' handles turning ' phy' , ' data' and ' names.col'
82+ arguments into a ' comparative.data' object when they are provided separately to
83+ a function . This argument structure was used in older versions of many
84+ functions.
5785
58- All of these functions are in part a substitute for the considerably more sophisticated handling of such data in the package ' phylobase' , which will be integrated into later releases.
86+ All of these functions are in part a substitute for the considerably more
87+ sophisticated handling of such data in the package ' phylobase' , which will be
88+ integrated into later releases.
5989}
90+
6091\value {
6192A list of class ' comparative.data' :
6293\item {phy }{An object of class ' phylo' }
0 commit comments