boot.compute.fj: Compute bootstrap resampled 'fj' as supplemental elements.

Description Usage Arguments Value Author(s) References See Also Examples

View source: R/boot.compute.fj.R

Description

This function computes a bootstrap resampled set of data and projects fj as supplemental elements.

Usage

1
boot.compute.fj(DATA, res, DESIGN = NULL, constrained = FALSE)

Arguments

DATA

The original data matrix to be bootstrapped. Rows will be bootstrapped and are assumed to be observations.

res

of class expoOutput. Results from one of the ExPosition methods (e.g., epPCA, epMCA),

DESIGN

A design matrix (in disjunctive coding). Only used if constrained is TRUE.

constrained

a boolean. If TRUE, bootstrap resampling will occur within groups as designated by the DESIGN matrix.

Value

fjj

a set of factor scores of the measures (columns, fj) for the bootstrapped data.

Author(s)

Derek Beaton

References

Chernick, M. R. (2008). Bootstrap methods: A guide for practitioners and researchers (Vol. 619). Wiley-Interscience.
Hesterberg, T. (2011). Bootstrap. Wiley Interdisciplinary Reviews: Computational Statistics, 3, 497–526.

See Also

See the functions supplementaryCols and link{boot.samples}

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
	##the following code generates 100 bootstrap resampled 
	##projections of the measures from the Iris data set.
	data(ep.iris)
	data <- ep.iris$data
	design <- ep.iris$design
	iris.pca <- epGPCA(data,scale="SS1",DESIGN=design,make_design_nominal=FALSE)
	boot.fjs.unconstrained <- array(0,dim=c(dim(iris.pca$ExPosition.Data$fj),100))
	boot.fjs.constrained <- array(0,dim=c(dim(iris.pca$ExPosition.Data$fj),100))
	for(i in 1:100){
		#unconstrained means we resample any of the 150 flowers
		boot.fjs.unconstrained[,,i] <- boot.compute.fj(ep.iris$data,iris.pca)
		#constrained resamples within each of the 3 groups
		boot.fjs.constrained[,,i] <- boot.compute.fj(data,iris.pca,design,TRUE)		
	}

InPosition documentation built on May 2, 2019, 7:59 a.m.