This function allows to perform various nonparametric test for homogeneity on two samples of circular data.

circular_test(x, y, test = "dixon", alpha = 0.05, B = NULL,
  type = "exact", seed = 1982)

Arguments

x

first sample

y

second sample

test

considered test (dixon for Dixon test (default); ww for Wheeler-Watson; wilcox for Wilcoxon test; rao for Rao test; vdw for van der Waerden test; savage for Savage test

alpha

significance level (default = 0.05)

B

number of bootstrap replications

seed

seed used for random number generation

type

method to compute pvalues (available methods: exact for exact computation (default) which is appropriate for small sample sizes; mc for approximation based on Monte-carlo simulations)

Value

A list with the following structure:

cv

a list containing the results of the exact distribution (NULL if type = "mc"), see function get_critical_values for details

mc

a list containing the results of the approximated distribution obtained by simulation (NULL if type = "exact"), see function MC_pvalue for details

B

number of bootstrap replications

alpha

significance level

test

the considered test

stat

observed test statistic

spacings

a list containing the observed spacings, see function compute_Sk for details

x

expression deparsing of the first dataset

y

expression deparsing of the second dataset

Examples

# Load dataset data(pigeons) # Dixon test (exact pvalue) circular_test(pigeons$experimental, pigeons$control)
#> #> Dixon Two Sample Test #> #> Data: pigeons$experimental and pigeons$control #> Test Statistic: 41 #> Exact P-value: 0.02096 #> Bracketing Points and Pair of Signif. Levels: #> c1 = 33 (p1 = 0.0567) #> c2 = 35 (p2 = 0.0460)
# Dixon test (approximated pvalue) circular_test( pigeons$experimental, pigeons$control, type = "mc")
#> #> Dixon Two Sample Test #> #> Data: pigeons$experimental and pigeons$control #> Test Statistic: 41 #> Approx. P-value: 0.0228 #> P-value stand. error: 0.0009575 #> based on 10000 Monte-Carlo replications