one-sample-stats {flipr}R Documentation

Test Statistics for the One-Sample Problem

Description

This is a collection of functions that provide test statistics to be used into the permutation scheme for performing one-sample testing.

Usage

stat_max(data, flips, ...)

Arguments

data

A list storing the sample from which the user wants to make inference.

flips

A numeric vectors of -1s and 1s to be used to randomly flip some data points around the center of symmetric of the distribution of the sample.

...

Extra parameters specific to some statistics.

Value

A numeric value evaluating the desired test statistic.

Examples

n <- 10
x <- as.list(rnorm(n))
flips <- sample(c(-1, 1), n, replace = TRUE)
stat_max(x, flips)

[Package flipr version 0.3.3 Index]