# mediantest: 2 Sample Median Test In nonpar: A Collection of Nonparametric Hypothesis Tests

## Description

The 2 sample median test is for testing the medians of 2 samples to see if they are equal.

## Usage

 `1` ``` mediantest(x, y, alpha=NULL, exact=FALSE) ```

## Arguments

 `x` A vector containing data from the first sample. `y` A vector containing data from the second sample. `alpha` The Significance level, defaults to 0.05. `exact` Defaults to FALSE. Runs the exact test or a large sample approximation.

## Value

 `Z` The test statistic for the large sample approximation. `P-value` Returns the p-value from the Median Test.

D. Lukke Sweet

## References

Higgins, J. J. (2005). An Introduction to modern nonparametric statistics. Belmont: Thomson Brooks/Cole.

Wiley Series in Probability and Statistics: Nonparametric Statistical Methods (3rd Edition). (2013). John Wiley & Sons.

## Examples

 ```1 2 3``` ``` ## Run the Median Test on the 2 vectors. mediantest(x = c(5.5, 5.8, 6.8, 6.9, 7.2, 7.3, 7.5, 7.6, 8.0), y = c(5.3, 5.4, 5.6, 5.7, 6.2, 6.4, 6.6, 6.7, 8.2), exact=TRUE) ```

nonpar documentation built on April 29, 2020, 9:36 a.m.