Title: | Robust Solution to the Behrens-Fisher Problem |
---|---|
Description: | Robust tests (RW and RF) are provided for testing the equality of two long-tailed symmetric (LTS) means when the variances are unknown and arbitrary. RW test is a robust version of Welch's two sample t test and the RF is a robust fiducial based test. The RW and RF tests are proposed using the adaptive modified maximum likelihood (AMML) estimators derived by Tiku and Surucu (2009) <doi:10.1016/j.spl.2008.12.001> and Donmez (2010) <https://open.metu.edu.tr/bitstream/handle/11511/19440/index.pdf>. |
Authors: | Gamze Guven [aut, cre], Sukru Acitas [aut], Hatice Samkar [aut], Birdal Senoglu [aut] |
Maintainer: | Gamze Guven <[email protected]> |
License: | GPL (>= 3) |
Version: | 0.2.0 |
Built: | 2024-10-31 22:12:53 UTC |
Source: | CRAN |
Computes p-value for the robust fiducial (RF) based test for the equality of means of two long-tailed symmetric (LTS) distributions when the variances are not equal.
RF(y1, y2, iter=5000)
RF(y1, y2, iter=5000)
y1 |
numeric vector of sample 1 |
y2 |
numeric vector of sample 2 |
iter |
the number of iterations for perfoming the RF test. |
RF test based on adaptive modified maximum likelihood (AMML) estimators (Tiku and Surucu, 2009; Donmez, 2010) is proposed using the fiducial model which is a special case of functional model given by Dawid and Stone (1982), see also Fisher (1933, 1935) for more information about the fiducial approach. It is one of the alternatives of Welch's t test (Welch, 1938) and its p-value is based on the iteration number. For further details, see Guven et al. (2021).
A list with class "htest
" containing the following components:
p.value |
the p-value for the RF test. |
estimate |
the AMML estimates of the location and scale parameters. |
null.value |
the specified hypothesized value of the mean difference. |
alternative |
a character string describing the alternative hypothesis. |
method |
a character string indicating which test is used. |
data.name |
a character string giving the name(s) of the data. |
Gamze Guven <[email protected]>
Dawid, A. P. and Stone, M. (1982). The functional-model basis of fiducial inference. The Annals of Statistics, 10(4):1054-1067.
Fisher, R. A. (1933). The concepts of inverse probability and fiducial probability referring to unknown parameters. Proceedings of Royal Society of London. Series A, 139(838):343-348
Fisher, R. A. (1935). The fiducial argument in statistical inference. Annals of eugenics, 6(4):391-398
Guven, G., Acitas, S., Samkar, H., Senoglu, B. (2021). RobustBF: An R Package for Robust Solution to the Behrens-Fisher Problem. RJournal (submitted).
Tiku, M. L. and Surucu, B. (2009). MMLEs are as good as M-estimators or better. Statistics & probability letters, 79(7):984-989.
Welch, B.L. (1938). The significance of the difference between two means when the population variances are unequal. Biometrika, 29(3/4):350–362.
# The following two samples (y1 and y2) # come from LTS distributions with # heterogeneous variances y1 <- c(0.55, 1.39, 2.01, 0.41, 0.32, -0.31, -1.06, -0.84, 1.02, 0.02, -0.96, 0.18, 0.49, 0.03, 0.77, 0.02, 0.56, 0.46, -0.65, -0.27) y2 <- c(7.25, 7.98, -0.24, 8.93, -0.16, 32.28, 3.81, 2.32, 14.73, 6.27, 8.07, 7.24, 7.18, 3.75, 11.48, 6.46, 1.01, 5.35, -0.34, 4.34) # RF test RF(y1, y2,5000)
# The following two samples (y1 and y2) # come from LTS distributions with # heterogeneous variances y1 <- c(0.55, 1.39, 2.01, 0.41, 0.32, -0.31, -1.06, -0.84, 1.02, 0.02, -0.96, 0.18, 0.49, 0.03, 0.77, 0.02, 0.56, 0.46, -0.65, -0.27) y2 <- c(7.25, 7.98, -0.24, 8.93, -0.16, 32.28, 3.81, 2.32, 14.73, 6.27, 8.07, 7.24, 7.18, 3.75, 11.48, 6.46, 1.01, 5.35, -0.34, 4.34) # RF test RF(y1, y2,5000)
Performs robust Welch's (RW) two sample t-test to test the equality of means of two long-tailed symmetric (LTS) distributions when the variances are not equal.
RW(y1, y2)
RW(y1, y2)
y1 |
numeric vector of sample 1 |
y2 |
numeric vector of sample 2 |
RW test based on adaptive modifed maximum likelihood (AMML) estimators is proposed as a robust alternative to Welch's t-test (Welch, 1938). The test statistic is formulated as follows
where and
are the AMML estimators of the location and scale parameters (
), see e.g. Tiku and Surucu (2009), Donmez (2010).
The null distribution of RW is approximately distributed as Student's t with degrees of freedom
For further details, see Guven et al. (2021)
A list with class "htest
" containing the following components:
statistic |
the value of the robust Welch's two sample t-test. |
parameter |
the degrees of freedom for the robust Welch's two sample t-test. |
p.value |
the p-value for the robust Welch's two sample t-test. |
estimate |
the AMML estimates of the location and scale parameters. |
null.value |
the specified hypothesized value of the mean difference. |
alternative |
a character string describing the alternative hypothesis. |
method |
a character string indicating which test is used. |
data.name |
a character string giving the name(s) of the data. |
Gamze Guven <[email protected]>
Donmez, A. (2010). Adaptive estimation and hypothesis testing methods [dissertation]. Ankara:METU.
Guven, G., Acitas, S., Samkar, H., Senoglu, B. (2021). RobustBF: An R Package for Robust Solution to the Behrens-Fisher Problem. RJournal (submitted).
Tiku, M. L. and Surucu, B. (2009). MMLEs are as good as M-estimators or better. Statistics & probability letters, 79(7):984-989.
Welch, B.L. (1938). The significance of the difference between two means when the population variances are unequal. Biometrika, 29(3/4):350–362.
# The following two samples (y1 and y2) # come from LTS distributions with # heterogeneous variances y1 <- c(0.55, 1.39, 2.01, 0.41, 0.32, -0.31, -1.06, -0.84, 1.02, 0.02, -0.96, 0.18, 0.49, 0.03, 0.77, 0.02, 0.56, 0.46, -0.65, -0.27) y2 <- c(7.25, 7.98, -0.24, 8.93, -0.16, 32.28, 3.81, 2.32, 14.73, 6.27, 8.07, 7.24, 7.18, 3.75, 11.48, 6.46, 1.01, 5.35, -0.34, 4.34) # RW test RW(y1, y2)
# The following two samples (y1 and y2) # come from LTS distributions with # heterogeneous variances y1 <- c(0.55, 1.39, 2.01, 0.41, 0.32, -0.31, -1.06, -0.84, 1.02, 0.02, -0.96, 0.18, 0.49, 0.03, 0.77, 0.02, 0.56, 0.46, -0.65, -0.27) y2 <- c(7.25, 7.98, -0.24, 8.93, -0.16, 32.28, 3.81, 2.32, 14.73, 6.27, 8.07, 7.24, 7.18, 3.75, 11.48, 6.46, 1.01, 5.35, -0.34, 4.34) # RW test RW(y1, y2)