formulaUnimva: Create a List of Univariate Formulas

Description Usage Arguments Value Author(s) See Also Examples

View source: R/formulaUnimva.R

Description

Create a list of m univariate formulas given a formula with multivariate response of dimension m.

Usage

1
2
formulaUnimva(formula, var.subset, split.x=FALSE, intercept=0,
  allow.noresp=FALSE)

Arguments

formula

a formula or a mvformula, the elements are not allowed to be data.frames.

var.subset

optional vector of the variable numbers to use.

split.x

logical, whether explanatory terms that are matrices should be split and each added as a single term. this is useful for plotting formulas.

intercept

numeric, either 1 if an Intercept should be included in the formula or 0 if there shouldn't be an Intercept in the formula.

allow.noresp

logical, whether an empty response is allowed (a list with one element would be returned) or not (would result in an error.)

Value

A list containing m formulas with the univariate responses chosen by var.subset.

Author(s)

Ulrike Naumann and David Warton <David.Warton@unsw.edu.au>.

See Also

mvformula, mvabund.

Examples

1
2
3
4
5
data(spider)
spiddat <- mvabund(spider$abund)
X <- spider$x

formulaUnimva(spiddat~X)

mvabund documentation built on May 19, 2017, 7:33 a.m.

Search within the mvabund package
Search all R packages, documentation and source code