yuend | R Documentation |
The function yuend
performs Yuen's test on trimmed means for dependent samples. Dqcomhd
compares the quantiles of the marginal distributions associated with two dependent groups via hd estimator. Tied values are allowed.
dep.effect
computes various effect sizes and confidence intervals for two dependent samples (see Details).
yuend(x, y, tr = 0.2, ...)
Dqcomhd(x, y, q = c(1:9)/10, nboot = 1000, na.rm = TRUE, ...)
dep.effect(x, y, tr = 0.2, nboot = 1000, ...)
x |
an numeric vector of data values (e.g. for time 1). |
y |
an numeric vector of data values (e.g. for time 2). |
tr |
trim level for the means. |
q |
quantiles to be compared. |
nboot |
number of bootstrap samples. |
na.rm |
whether missing values should be removed. |
... |
currently ignored. |
The test statistic is a paired samples generalization of Yuen's independent samples t-test on trimmed means.
dep.effect
computes the following effect sizes:
AKP: robust standardized difference similar to Cohen's d
QS: Quantile shift based on the median of the distribution of difference scores,
QStr: Quantile shift based on the trimmed mean of the distribution of X-Y
SIGN: P(X<Y), probability that for a random pair, the first is less than the second.
yuend
returns an object of class "yuen"
containing:
test |
value of the test statistic (t-statistic) |
p.value |
p-value |
conf.int |
confidence interval |
df |
degress of freedom |
diff |
trimmed mean difference |
call |
function call |
Dqcomhd
returns an object of class "robtab"
containing:
partable |
parameter table |
dep.effect
returns a matrix with the null value of the effect size, the estimated effect size, small/medium/large conventions, and lower/upper CI bounds.
Wilcox, R. (2012). Introduction to Robust Estimation and Hypothesis Testing (3rd ed.). Elsevier.
yuen
, qcomhd
## Cholesterol data from Wilcox (2012, p. 197)
before <- c(190, 210, 300,240, 280, 170, 280, 250, 240, 220)
after <- c(210, 210, 340, 190, 260, 180, 200, 220, 230, 200)
yuend(before, after)
set.seed(123)
Dqcomhd(before, after, nboot = 200, q = c(0.25, 0.5, 0.75))
set.seed(123)
dep.effect(before, after)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.