Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

spearman.test

Spearman test for time series trends


Description

The function uses the non parametric Spearman test to assess the presence of significant trends in the time series

Usage

spearman.test(timeseries, years)

Arguments

timeseries

data frame of the indices time series as it is estimated by the index.ts function

years

vector of the time series year range

Details

In presence of a short trawl survey time series the significance of the trend can be estimated using nonparametric statistical tests as Spearman rho (Cotter, 2009). Spearman's rho is the product-moment correlation between the ranks of paired data. To test for trend, one member of the pair is the time of observation, the other is the observed variable. This is also known as the Hotelling-Pabst test. It appears to be sensitive to monotonic trends.

Value

The function returns the statistics of the Spearman's test.

r

Spearman's correlation coefficient.

p

t statistics.

p

the p-value for the test.

Author(s)

Walter Zupa

References

Cotter J. (2009) A selection of nonparametric statistical methods for assessing trends in trawl survey indicators as part of an ecosystem approach to fisheries management (EAFM). Aquat. Living Resour. 22, 173-185.

Examples

library(MEDITS)
merge_TATB <- m.TATB(TA,TB,"ARISFOL")
timeseries <- index.ts(merge_TATB, index="abundance", depth_range = c(500,800),
str.scheme=strata_scheme,surf=stratification_scheme, plot=FALSE)
spearman.test(timeseries, years=c(2007,2016))

MEDITS

Analysis of MEDITS-Like Survey Data

v0.1.7
GPL-3
Authors
Walter Zupa, Loredana Casciaro, Isabella Bitetto, Maria Teresa Spedicato
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.