designTree {phangorn}R Documentation

Compute a design matrix

Description

designTree and designSplits compute design matrices for the estimation of edge length of (phylogenetic) trees using linear models. designTree also computes a contrast matrix if the method is "rooted".

Usage

designTree(tree, method = "unrooted", ...)
designSplits(x, splits = "all", ...)

Arguments

tree an object of class phylo
method design matrix for an "unrooted" or "rooted" ultrametric tree
x number of taxa.
splits one of "all", "star"
... further arguments, passed to other methods.

Value

a matrix.

Author(s)

Klaus Schliep K.P.Schliep@massey.ac.nz

See Also

fastme, distanceHadamard

Examples

example(NJ)
dm <-  as.matrix(dm)
y <- dm[lower.tri(dm)]
X <- designTree(tree)
summary(lm(y~X-1))

[Package phangorn version 0.0-5 Index]