build2popData_muYafunction: Data simulator for the high-dimensional two-sample setting

Description Usage Arguments Value Author(s) References Examples

Description

Generates data from two populations with user-specified mean vectors, that of population two a function which returns the vector of means, covariance structure, sample sizes, and dimension of each observation.

Usage

1
2
3
build2popData_muYafunction(n, m, p, muX, muY, dep, commoncov, VarScaleY, 
 ARMAparms, LRparm,S = 1, innov = function(n, ...) rnorm(n, 0, 1),
 heteroscedastic = FALSE, het.diag)

Arguments

n

number of observations in sample one.

m

number of observations in sample two.

p

number of components in each observation.

muX

p by 1 vector of component means for population one.

muY

p by 1 a function returning a vector of length p which whill serve as the vector of component means for population two.

dep

dependence structure among the p components for both populations. Choices are 'IND', 'ARMA', and 'LR'.

commoncov

a logical indicating whether populations one and two will have equal covariance matrices. If FALSE, then the innovations used in generating the population two data will be scaled by the square root of the value specifed in VarScaleY.

VarScaleY

constant by which innovations are scaled in generating observations for sample two when commoncov=FALSE.

ARMAparms

a list of the form list(coefs=list(ma= , ar=)) specifying the AR and MA parameters to be used when dep='ARMA'.

LRparm

value of the LR dependence parameter to be used when dep='LR'.

S

the number of data sets to simulate.

innov

a function used to generate the innovations, such as innov=function(n,...) rnorm(n,0,1).

heteroscedastic

a logical indicating whether the components will be scaled by the entries in the diagonal matrix specified by het.diag=.

het.diag

a p by p diagonal matrix, where the entries on the diagonal will be used to scale the component standard deviations.

Value

A list of length S of lists, each containing

X

the n by p data matrix for sample one.

Y

the m by p data matrix for sample two.

n

the number of observations in sample one.

m

the number of observation in sample two.

p

the number of components in each observation.

muX

the mean vector for population one.

muY

the mean vector for population two.

dep

the dependence structure chosen for dep.

commoncov

the value of commoncov used in the function call.

VarScaleY

the scalar by which the variance of the population two data is scaled.

ARMAparms

the list containing the specified ARMA parameters.

LRparm

the long-range dependence parameter.

S

the number of simulated data sets.

innov

the function chosen to generate the innovations.

heteroscedastic

logical indicating whether heteroscedastic=TRUE in the function call.

het.diag

the value of het.diag in the function call.

Author(s)

Karl Gregory kgregory@mail.uni-mannheim.de, http://www.stat.tamu.edu/~kbgregory.

References

Hall, P. Jing, B. Y. and Lahiri, S. N. (1998). On the sampling window method for long-range dependent data. Statistica Sinica 8,1189–1204

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
## Not run: 
DATA <-build2popData(	
	n = 15,
	m = 20,
	p = 500,
	muX = rep(0,500),
	muY = rep(0,500),
	commoncov = FALSE,
	VarscaleY = 2,
	dep = "ARMA",
	ARMAparms = list(coefs=list(ma=c(.2,.3) , ar=c(.4,-.1))),
	LRparm = .75,
	S = 25,
	innov = function(n,...) rnorm(n,0,1),
	heteroscedastic=TRUE,
	het.diag = diag(.1 + rexp(500,1/2))
	)

## End(Not run)

highD2pop documentation built on May 2, 2019, 5:11 a.m.