Cox-Stuart test for trend analysis The Cox-Stuart test is defined as a little powerful test (power equal to 0.78), but very robust for the trend analysis. It is therefore applicable to a wide variety of situations, to get an idea of the evolution of values obtained. The proposed method is based on the binomial distribution. This function was written by Tommaso Martino<todoslogos@gmail.com> (See 'References')

cox.stuart.test(x)

Arguments

x

A numeric vector

Value

A list with class "htest"

References

Original code: http://statistic-on-air.blogspot.kr/2009/08/trend-analysis-with-cox-stuart-test-in.html

Examples

customers = c(5, 9, 12, 18, 17, 16, 19, 20, 4, 3, 18, 16, 17, 15, 14) cox.stuart.test(customers)
#> #> Cox-Stuart test for trend analysis #> #> data: #> Decreasing trend, p-value = 0.10938 #>