correlatedTtest | R Documentation |
This function performs the correlated version of the t-test for paired samples
correlatedTtest(x, y = NULL, rho, alternative = "two.sided")
x |
First sample |
y |
Second sample (if not provided, x is tested aginst 0) |
rho |
Correlation factor (see details) |
alternative |
a character string specifying the alternative hypothesis, must be one of "two.sided" (default), "greater" or "less". You can specify just the initial letter. |
This version of the t-test takes into account the correlation between samples. for the particular case of cross validated results, the heuristic to set the correlation is size of test set divided by total size of the dataset.
A list with class "htest" containing the following components: statistic
, the value of the statistic used in the test; method
, a character string indicating what type of test was performed; data.name
, a character string giving the name of the data and diff.matirx
, a matrix with all the pairwise absolute difference of average values.
C. Nadeau and Y. Bengio (2003) Inference for the Generalization Error. Machine Learning, 52(3), 239-281.
sample1 <- rnorm(25, 1, 1)
sample2 <- rnorm(25, 1.2, 1)
correlatedTtest (x=sample1, y=sample2, rho=0.1, alternative="less")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.