Package: season 0.3.16.9000

season: Seasonal Analysis of Health Data

Routines for the seasonal analysis of health data, including regression models, time-stratified case-crossover, plotting functions and residual checks, see Barnett and Dobson (2010) ISBN 978-3-642-10748-1. Thanks to Yuming Guo for checking the case-crossover code.

Authors:Adrian Barnett [aut, cre], Peter Baker [aut], Nicholas Tierney [aut]

season_0.3.16.9000.tar.gz
season_0.3.16.9000.zip(r-4.7)season_0.3.16.9000.zip(r-4.6)season_0.3.16.9000.zip(r-4.5)
season_0.3.16.9000.tgz(r-4.6-any)season_0.3.16.9000.tgz(r-4.5-any)
season_0.3.16.9000.tar.gz(r-4.7-any)season_0.3.16.9000.tar.gz(r-4.6-any)
season_0.3.16.9000.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION |NEWS
card.svg |card.png
season/json (API)

# Install 'season' in R:
install.packages('season', repos = c('https://agbarnett.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/agbarnett/season/issues

Pkgdown/docs site:https://agbarnett.github.io

Datasets:
  • AFL - Australian Football League (AFL) Players' Birthdays for the 2009 Season
  • CVD - Cardiovascular Deaths in Los Angeles, 1987-2000
  • CVDdaily - Daily Cardiovascular Deaths in Los Angeles, 1987-2000
  • exercise - Exercise Data from Queensland, 2005-2007
  • indoor - Indoor Temperature Data
  • schz - Schizophrenia Births in Australia, 1930-1971
  • stillbirth - Stillbirths in Queensland, 1998-2000

On CRAN:

Conda:

non-linearseasonstime-series

7.64 score 3 stars 91 scripts 418 downloads 11 mentions 28 exports 36 dependencies

Last updated from:c3b57ee382. Checks:9 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64OK236
source / vignettesOK428
linux-release-x86_64OK210
macos-release-arm64OK123
macos-oldrel-arm64OK154
windows-develOK161
windows-releaseOK161
windows-oldrelOK149
wasm-releaseOK136

Exports:aaftaugmentautoplotcasecrossciPhasecosinorcreateAdjglanceinvyrfractioninvyrfraction_chrinvyrfraction_nummonthglmmonthmeannonlintestnscosinorperiphasecalcplot_circleplot_monthplotCircleplotCircularplotMonthseasreschecksinusoidthirdtidywtestyrfraction

Dependencies:backportsbroomclicodacpp11dplyrfarvergenericsggplot2gluegtableisobandlabelinglatticelifecyclemagrittrMASSMatrixpillarpkgconfigpurrrR6RColorBrewerrlangS7scalesstringistringrsurvivaltibbletidyrtidyselectutf8vctrsviridisLitewithr

Modelling monthly data
Monthly data | Month as a fixed effect | Month as a random effect | Month as a correlated random effect

Last update: 2026-05-12
Started: 2026-05-04

Season tutorial
Seasonal death data | Plot of deaths over time | Daily deaths and temperatures plot | Regression model | Confidence intervals | Plot of the non-linear association between temperature and death | Plot of the temperature and death association averaging over all lags | Plot of the lagged temperature and death association for a specific temperature | Non-stationary seasonal patterns | Back transforming the phase | Testing for non-linearity in time series

Last update: 2026-05-12
Started: 2018-09-02

Readme and manuals

Help Manual

Help pageTopics
Amplitude Adjusted Fourier Transform (AAFT)aaft
Australian Football League (AFL) Players' Birthdays for the 2009 SeasonAFL
Augmentaugment.casecross
Plot the fitted sinusoid from a 'cosinor()' modelautoplot.Cosinor
Plot the monthly estimates from 'monthglm()'autoplot.monthglm
Plot the monthly mean estimates from 'monthmean()'autoplot.Monthmean
Plot the region of the third-order moment outside the test limitsautoplot.nonlintest
Plot the trend and seasonal estimates from 'nscosinor()'autoplot.nsCosinor
Plot the periodogram from 'peri()'autoplot.peri
Plot the third-order moment from 'third()'autoplot.third
Case-crossover Analysis to Control for Seasonalitycasecross
Mean and Confidence Interval for Circular PhaseciPhase
Cosinor Regression Model for Detecting Seasonality in Yearly Data or Circadian Patterns in Hourly Datacosinor
Creates an Adjacency MatrixcreateAdj
Cardiovascular Deaths in Los Angeles, 1987-2000CVD
Daily Cardiovascular Deaths in Los Angeles, 1987-2000CVDdaily
Exercise Data from Queensland, 2005-2007exercise
Construct a single row summary "glance" of a model, fit, or other objectglance.casecross
Indoor Temperature Dataindoor
Inverts a fraction of the year or hour to a useful time scale.invyrfraction invyrfraction_chr invyrfraction_num
Fit a GLM with Monthmonthglm
Calculate monthly mean or adjusted monthly mean for count data.monthmean
Test of Non-linearity of a Time Seriesnonlintest
Non-stationary Cosinornscosinor
Periodogramperi
Phase from Cosinor Estimatesphasecalc
Circular plot of monthly values (ggplot2)plot_circle
Plot a response by month (ggplot2)plot_month
Plot the Results of a Cosinorplot.Cosinor
Plot of Monthly Estimatesplot.monthglm
Plot of Monthly Mean Estimatesplot.Monthmean
Plot the Results of the Non-linear Testplot.nonlintest
Plot the Results of a Non-stationary Cosinorplot.nsCosinor
Circular PlotplotCircle
Circular Plot Using SegmentsplotCircular
Plot Results by MonthplotMonth
Print the Results of a Case-Crossover Modelprint.casecross
Prints basic results from 'monthglm()'print.monthglm
Print the Results from Monthmeanprint.Monthmean
Print the Results of the Non-linear Testprint.nonlintest
Print the Results of a Non-stationary Cosinorprint.nsCosinor
Printing a summary of a month.glmprint.summary.monthglm
Print a summary of an 'nscosinor()' objectprint.summary.nsCosinor
Schizophrenia Births in Australia, 1930-1971schz
Seasonal Residual Checksseasrescheck
Plot a Sinusoidsinusoid
Stillbirths in Queensland, 1998-2000stillbirth
Summary of the Results of a Case-crossover Modelsummary.casecross
Print and summary methods for a Cosinorprint.Cosinor print.summary.Cosinor summary.Cosinor
Summary for a Monthglmsummary.monthglm
Summary for a Non-stationary Cosinorsummary.nsCosinor
Third-order Momentthird
Tidy a casecross objecttidy.casecross
Walter and Elwood's Test of Seasonalitywtest
Fraction of the Yearyrfraction