varGroup {qtlmt}R Documentation

Group variables

Description

Group variables via variable selection such that the grouped variables are optimal for multivariate analysis.

Usage

varGroup(x, z, zscope=NULL, k=qf(0.95,1,nrow(x)-2), kf=k/2,
   method=c("pool","best"), direction=c("both","forward","backward"))

Arguments

x

a data matrix/frame. Columns are variables to select from.

z

a data matrix/frame. Columns are variables with elements 1 or not 1 (any others).

zscope

which variables in z to be used for grouping; all if "NULL".

k

entry/stay value in backward stepwise.

kf

entry/stay value in forward stepwise.

method

grouping method at each step: pool all the groups selected from each zcope variable, or choose the largest group (see examples).

direction

forward selection, backward elimination or both stepwise.

Value

indicators of grouped variables.

Examples

data(etrait)
varGroup(traits, mdat, zscope=c(42,55), method="pool")
varGroup(traits, mdat, zscope=c(42,55), method="best")

[Package qtlmt version 0.1-6 Index]