permb: Permutation Based Tests for Incomplete Paired Data

Description Usage Arguments Value References Examples

View source: R/permb.R

Description

The function Performs testing the hypothesis of equality of means for the incomplete pairs setting data. The function combines the observed mean difference for the complete pairs with the difference between the two means of the independent samples. The function implements two different nonparametric tests based on permutation tests that were proposed by Einsporn and Habtzghi (2013), and Maritz (1995). The two methods are denoted by EH and Maritz, respectively.

Usage

1
2
permb(xp, yp, xu, yu, r, mu = NULL, method = "EH",
      alternative = "two.sided", verbose = TRUE)

Arguments

xp, yp

(non-empty) numeric vectors of data values of the the complete pairs

xu

a numeric vector of data on x only

yu

a numeric vector of data on y only

r

a number indicating the correlation between the complete pairs

mu

a number indicating the true value of the mean (or difference in means if you are performing a two sample test)

method

a character string specifying the different type of methods, must be one of "EH" (default) or "Maritz"

alternative

a character string specifying the alternative hypothesis, must be one of "two.sided" (default), "greater" or "less"

verbose

if TRUE, show the test used, null and alternative hypotheses in addition to the p-value

Value

A S4 object containing the following components:

Title

a character string describing the test used

Nhypothesis

a character string describing the null hypothesis

Ahypothesis

a character string describing the alternative hypothesis

Pval

the p-value for the test

References

1 Einsporn, R. L., & Habtzghi, D. (2013). Combining paired and two-sample data using a permutation test. Journal of Data Science, 11(4), 767-779.

2 Maritz, J. S. (1995). A permutation paired test allowing for missing values. Australian Journal of Statistics, 37(2), 153-159.

3 Woolson, R., Leeper, J., Cole, J. and Clarke, W. (1976). A Monte Carlo investigation of a statistic for a bivariate missing data problem. Communications in Statistics - Theory and Methods A5, 681-688.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
n=20
n1=15
n2=10
r=0.8
xp=rnorm(n)
yp=r*xp+(1-r)*(rnorm(n))
xu=rnorm(n1)
yu=rnorm(n2)
mu=0
permb(xp,yp,xu,yu,r,mu,method="Maritz",alternative="two.sided")

IncomPair documentation built on March 26, 2020, 6:34 p.m.

Related to permb in IncomPair...