Use R!: Introductory Time Series with R (Paperback)

Paul S P Cowpertwait; Andrew V Metcalfe
Springer New York
9780387886978
0-387-88697-4

Rhasacommandlineinterfacethato?ersconsiderableadvantagesovermenu systemsintermsofe?ciencyandspeedoncethecommandsareknownandthe languageunderstood. However, thecommandlinesystemcanbedauntingfor the?rst-timeuser,.

read more…

sothereisaneedforconcisetextstoenablethestudentor analysttomakeprogresswithRintheirareaofstudy. Thisbookaimstoful?l thatneedintheareaoftimeseries toenablethenon-specialisttoprogress, atafairlyquickpace, toalevelwheretheycancon?dentlyapplyarangeof timeseriesmethodstoavarietyofdatasets. Thebookassumesthereader hasaknowledgetypicalofa?rst-yearuniversitystatisticscourseandisbased aroundlecturenotesfromarangeoftimeseriescoursesthatwehavetaught overthelasttwentyyears. Someofthismaterialhasbeendeliveredtopo- graduate?nancestudentsduringaconcentratedsix-weekcourseandwaswell received, soaselectionofthematerialcouldbemasteredinaconcentrated course, althoughingeneralitwouldbemoresuitedtobeingspreadovera completesemester. Thebookisbasedaroundpracticalapplicationsandgenerallyfollowsa similar format for each time series model being studied. First, there is an introductory motivational section that describes practical reasons why the modelmaybeneeded. Second, themodelisdescribedandde?nedinma- ematicalnotation. Themodelisthenusedtosimulatesyntheticdatausing Rcodethatcloselyre?ectsthemodelde?nitionandthen?ttedtothes- theticdatatorecovertheunderlyingmodelparameters. Finally, themodel is?ttedtoanexamplehistoricaldatasetandappropriatediagnosticplots given. By using R, the whole procedure can be reproduced by the reader, 1 anditisrecommendedthatstudentsworkthroughmostoftheexamples. Mathematical derivations are provided in separate frames and starred sec- 1 WeusedtheRpackageSweavetoensurethat, ingeneral, yourcodewillproduce thesameoutputasours. However, forstylisticreasonswesometimeseditedour code;e. g., fortheplotstherewillsometimesbeminordi?erencesbetweenthose generatedbythecodeinthetextandthoseshownintheactual?gures. vii viii Preface tionsandcanbeomittedbythosewantingtoprogressquicklytopractical applications. Attheendofeachchapter, aconcisesummaryoftheRc- mands that were used is given followed by exercises. All data sets used in thebook, andsolutionstotheoddnumberedexercises, areavailableonthe websitehttp: //www. massey. ac. nz/?pscowper/ts. WethankJohnKimmelofSpringerandtheanonymousrefereesfortheir helpfulguidanceandsuggestions, BrianWebbyforcarefulreadingofthetext andvaluablecomments, andJohnXieforusefulcommentsonanearlierdraft. TheInstituteofInformationandMathematicalSciencesatMasseyUniv- sity and the School of Mathematical Sciences, University of Adelaide, are acknowledgedforsupportandfundingthatmadeourcollaborationpossible. Paul thanks his wife, Sarah, for her continual encouragement and support duringthewritingofthisbook, andourson, Daniel, anddaughters, Lydia andLouise, forthejoytheybringtoourlives. AndrewthanksNataliefor providinginspirationandherenthusiasmfortheproject. PaulCowpertwaitandAndrewMetcalfe MasseyUniversity, Auckland, NewZealand UniversityofAdelaide, Australia December2008 Contents Preface. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii 1 TimeSeriesData. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1. 1 Purpose. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1 1. 2 Timeseries. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2 1. 3 Rlanguage. . . . . . . . . . . . . . . . . . . . . . . . .