mv.2sample.est | R Documentation |
Estimates the multivariate shift for different score functions and their asymptotic covariance matrices in the two sample case.
mv.2sample.est(X, g, score = "identity", stand = "outer",
maxiter = 100, eps = 1e-06, na.action = na.fail,
...)
X |
a numeric data frame or matrix. |
g |
a factor with two levels |
score |
the score to be used. Possible choices are |
stand |
the standardization method used. Possible choices are |
maxiter |
maximum number of iterations. Used only for |
eps |
convergence tolerance. Used only for |
na.action |
a function which indicates what should happen when the data contain 'NA's. Default is to fail. |
... |
arguments that can be passed on to functions used for the estimation of location. |
This implements the location estimates and their asymptotic covariance matrices as described in chapter 11 of the MNM book.
Note that the shift is the parameter for the defference between 'values of level 1 - values of level 2' where the levels are as defined in the factor g
.
For the general c sample location case the function mv.l1lm
might be used.
A list with class 'mvloc' containing the following components:
location |
the location estimate as a vector. |
vcov |
the asymptotic covariance matrix of the location estimate. |
est.name |
name of the location estimate. |
dname |
name of data set for which the location was computed. |
Klaus Nordhausen
Oja, H. (2010), Multivariate Nonparametric Methods with R, Springer.
Nordhausen, K. and Oja, H. (2011), Multivariate L1 Methods: The Package MNM, Journal of Statistical Software, 43, 1-28.
spatial.sign
, spatial.signrank
X1<- rmvnorm(50,c(0,0,0))
X2<- rmvnorm(70,c(1,1,2))
X<-rbind(X1,X2)
g<-factor(rep(1:2,c(50,70)))
est.Hot.X <- mv.2sample.est(X, g)
est.SS.o.X <- mv.2sample.est(X, g, "s")
est.SS.i.X <- mv.2sample.est(X, g, "s", "i")
est.SR.o.X <- mv.2sample.est(X, g, "r")
est.SR.i.X <- mv.2sample.est(X, g, "r", "i")
est.SS.o.X
summary(est.SS.o.X)
# plotting
plotMvloc(est.Hot.X, est.SS.i.X, est.SR.i.X)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.