{
  "name": "R Hypothesis Testing Function Configurations and Assumptions",
  "description": "Comparative specifications of hypothesis testing functions in base R (stats package), detailing parameter signatures, variance assumptions, output class structures, and degrees of freedom calculations across experimental designs.",
  "page": "https://casrai.org/guides/t-test-rstudio",
  "publisher": "CASRAI",
  "license": "https://creativecommons.org/licenses/by/4.0/",
  "dateModified": "2026-11-16T22:05:33Z",
  "temporalCoverage": "2024/2026",
  "spatialCoverage": "International",
  "columns": [
    {
      "name": "Test Design",
      "unit": "",
      "description": "Experimental hypothesis testing structure"
    },
    {
      "name": "Function Call Syntax",
      "unit": "",
      "description": "R command invocation syntax in the stats package"
    },
    {
      "name": "Null Hypothesis",
      "unit": "",
      "description": "Mathematical statement of H0"
    },
    {
      "name": "Degrees of Freedom Formula",
      "unit": "",
      "description": "Mathematical calculation for df parameter"
    },
    {
      "name": "Variance Assumption",
      "unit": "",
      "description": "Homoscedasticity requirement"
    },
    {
      "name": "S3 Output Class",
      "unit": "",
      "description": "R object class returned"
    },
    {
      "name": "Default Confidence Level",
      "unit": "%",
      "description": "Default coverage interval percentage"
    }
  ],
  "rows": [
    {
      "Test Design": "One-Sample t-Test",
      "Function Call Syntax": "t.test(x, mu = 0)",
      "Null Hypothesis": "mu = mu_0",
      "Degrees of Freedom Formula": "n - 1",
      "Variance Assumption": "Not Applicable (single sample)",
      "S3 Output Class": "htest",
      "Default Confidence Level": 95
    },
    {
      "Test Design": "Welch Two-Sample t-Test",
      "Function Call Syntax": "t.test(x, y, var.equal = FALSE)",
      "Null Hypothesis": "mu_1 - mu_2 = 0",
      "Degrees of Freedom Formula": "Welch-Satterthwaite approximation",
      "Variance Assumption": "Unequal variances assumed",
      "S3 Output Class": "htest",
      "Default Confidence Level": 95
    },
    {
      "Test Design": "Student Two-Sample t-Test",
      "Function Call Syntax": "t.test(x, y, var.equal = TRUE)",
      "Null Hypothesis": "mu_1 - mu_2 = 0",
      "Degrees of Freedom Formula": "n1 + n2 - 2 (pooled variance)",
      "Variance Assumption": "Equal variances required",
      "S3 Output Class": "htest",
      "Default Confidence Level": 95
    },
    {
      "Test Design": "Paired-Sample t-Test",
      "Function Call Syntax": "t.test(x, y, paired = TRUE)",
      "Null Hypothesis": "mu_d = 0",
      "Degrees of Freedom Formula": "n_pairs - 1",
      "Variance Assumption": "Differences normally distributed",
      "S3 Output Class": "htest",
      "Default Confidence Level": 95
    },
    {
      "Test Design": "Directional Greater t-Test",
      "Function Call Syntax": "t.test(x, y, alternative = 'greater')",
      "Null Hypothesis": "mu_1 - mu_2",
      "Degrees of Freedom Formula": "Design dependent (n-1 or Welch)",
      "Variance Assumption": "Determined by var.equal",
      "S3 Output Class": "htest",
      "Default Confidence Level": 95
    },
    {
      "Test Design": "Directional Less t-Test",
      "Function Call Syntax": "t.test(x, y, alternative = 'less')",
      "Null Hypothesis": "mu_1 - mu_2 >= 0",
      "Degrees of Freedom Formula": "Design dependent (n-1 or Welch)",
      "Variance Assumption": "Determined by var.equal",
      "S3 Output Class": "htest",
      "Default Confidence Level": 95
    },
    {
      "Test Design": "Wilcoxon Rank-Sum Alternative",
      "Function Call Syntax": "wilcox.test(x, y)",
      "Null Hypothesis": "median_1 - median_2 = 0",
      "Degrees of Freedom Formula": "Rank-sum distribution (asymptotic)",
      "Variance Assumption": "Similar distribution shape",
      "S3 Output Class": "htest",
      "Default Confidence Level": 95
    }
  ],
  "sources": [
    {
      "title": "R stats Package Documentation: t.test",
      "url": "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/t.test.html",
      "accessed": "2026-11-14"
    },
    {
      "title": "R stats Package Documentation: wilcox.test",
      "url": "https://stat.ethz.ch/R-manual/R-devel/library/stats/html/wilcox.test.html",
      "accessed": "2026-11-14"
    },
    {
      "title": "Welch (1947): The Generalization of Student's Problem",
      "url": "https://doi.org/10.2307/2332410",
      "accessed": "2026-11-14"
    }
  ]
}