Diane Stockton Trend analysis. Introduction Why do we want to look at trends over time? –To see how things have changed What is the information used for?

Slides:



Advertisements
Similar presentations
©The McGraw-Hill Companies, Inc. 2008McGraw-Hill/Irwin Lesson 12.
Advertisements

Part II – TIME SERIES ANALYSIS C3 Exponential Smoothing Methods © Angel A. Juan & Carles Serrat - UPC 2007/2008.
Forecasting OPS 370.
Forecasting Using the Simple Linear Regression Model and Correlation
Inference for Regression
Part II – TIME SERIES ANALYSIS C5 ARIMA (Box-Jenkins) Models
Regression Analysis Module 3. Regression Regression is the attempt to explain the variation in a dependent variable using the variation in independent.
Regression Analysis Once a linear relationship is defined, the independent variable can be used to forecast the dependent variable. Y ^ = bo + bX bo is.
Time Series Analysis Autocorrelation Naive & Simple Averaging
Moving Averages Ft(1) is average of last m observations
Chapter 5 Time Series Analysis
1 Spreadsheet Modeling & Decision Analysis: A Practical Introduction to Management Science, 3e by Cliff Ragsdale.
Chapter 3 Forecasting McGraw-Hill/Irwin
Part II – TIME SERIES ANALYSIS C2 Simple Time Series Methods & Moving Averages © Angel A. Juan & Carles Serrat - UPC 2007/2008.
Forecasting McGraw-Hill/Irwin Copyright © 2012 by The McGraw-Hill Companies, Inc. All rights reserved.
© 2000 Prentice-Hall, Inc. Chap Forecasting Using the Simple Linear Regression Model and Correlation.
Statistical Forecasting Models
Correlation and Regression Analysis
Regression Model Building Setting: Possibly a large set of predictor variables (including interactions). Goal: Fit a parsimonious model that explains variation.
Copyright ©2006 Brooks/Cole, a division of Thomson Learning, Inc. More About Regression Chapter 14.
McGraw-Hill/Irwin Copyright © 2010 by The McGraw-Hill Companies, Inc. All rights reserved. Time Series and Forecasting Chapter 16.
Business Forecasting Chapter 5 Forecasting with Smoothing Techniques.
Time Series and Forecasting
Slides 13b: Time-Series Models; Measuring Forecast Error
1 BABS 502 Moving Averages, Decomposition and Exponential Smoothing Revised March 11, 2011.
Forecasting using trend analysis
Objectives of Multiple Regression
Slides by John Loucks St. Edward’s University.
Introduction to Linear Regression and Correlation Analysis
Inference for regression - Simple linear regression
Time Series “The Art of Forecasting”. What Is Forecasting? Process of predicting a future event Underlying basis of all business decisions –Production.
The Importance of Forecasting in POM
Regression Method.
Simple Linear Regression
Chapter 12 Multiple Regression and Model Building.
Simple Linear Regression Models
1 Least squares procedure Inference for least squares lines Simple Linear Regression.
©2013 Cengage Learning. All Rights Reserved. May not be scanned, copied or duplicated, or posted to a publicly accessible website, in whole or in part.
1 Spreadsheet Modeling & Decision Analysis: A Practical Introduction to Management Science, 3e by Cliff Ragsdale.
Copyright © 2015 McGraw-Hill Education. All rights reserved. No reproduction or distribution without the prior written consent of McGraw-Hill Education.
The Examination of Residuals. Examination of Residuals The fitting of models to data is done using an iterative approach. The first step is to fit a simple.
DSc 3120 Generalized Modeling Techniques with Applications Part II. Forecasting.
Geographic Information Science
1 DSCI 3023 Forecasting Plays an important role in many industries –marketing –financial planning –production control Forecasts are not to be thought of.
Operations Management For Competitive Advantage 1Forecasting Operations Management For Competitive Advantage Chapter 11.
Examining Relationships in Quantitative Research
Time Series Analysis and Forecasting
Copyright © 2011 Pearson Education, Inc. The Simple Regression Model Chapter 21.
Inference for Regression Simple Linear Regression IPS Chapter 10.1 © 2009 W.H. Freeman and Company.
Forecasting Operations Management For Competitive Advantage.
© Copyright McGraw-Hill Correlation and Regression CHAPTER 10.
Copyright ©2011 Brooks/Cole, Cengage Learning Inference about Simple Regression Chapter 14 1.
Time Series Analysis and Forecasting. Introduction to Time Series Analysis A time-series is a set of observations on a quantitative variable collected.
Chapter 8: Simple Linear Regression Yang Zhenlin.
1 BABS 502 Moving Averages, Decomposition and Exponential Smoothing Revised March 14, 2010.
1 1 Chapter 6 Forecasting n Quantitative Approaches to Forecasting n The Components of a Time Series n Measures of Forecast Accuracy n Using Smoothing.
Forecasting is the art and science of predicting future events.
Paul Fryers Deputy Director, EMPHO Technical Advisor, APHO Introduction to Correlation and Regression Contributors Shelley Bradley, EMPHO Mark Dancox,
Managerial Decision Modeling 6 th edition Cliff T. Ragsdale.
Chapter 15 Forecasting. Forecasting Methods n Forecasting methods can be classified as qualitative or quantitative. n Such methods are appropriate when.
F5 Performance Management. 2 Section C: Budgeting Designed to give you knowledge and application of: C1. Objectives C2. Budgetary systems C3. Types of.
Time Series Forecasting Trends and Seasons and Time Series Models PBS Chapters 13.1 and 13.2 © 2009 W.H. Freeman and Company.
Stats Methods at IC Lecture 3: Regression.
Short-Term Forecasting
Chapter 4 Basic Estimation Techniques
Forecasting Methods Dr. T. T. Kachwala.
CHAPTER 29: Multiple Regression*
DSS-ESTIMATING COSTS Cost estimation is the process of estimating the relationship between costs and cost driver activities. We estimate costs for three.
Forecasting Plays an important role in many industries
Presentation transcript:

Diane Stockton Trend analysis

Introduction Why do we want to look at trends over time? –To see how things have changed What is the information used for? –Needs assessment –Programme planning –Programme evaluation –Policy development –To set targets for improving services or outcomes –To monitor progress against targets –To make predictions about the future

–The overall pattern of change in an indicator over time –Comparing one time period to another time period (interrupted time series data) –Comparing one geographic area to another –Comparing one population to another –Making future projections Analysis of time trends can focus on:

Important issues Sample size Presence of extreme observations Availability of numerator and denominator data Confounding

Statistical procedures Linear regression Log-linear regression Logistic regression Poisson regression Time series (seasonal or otherwise) Specialised models

What is a linear trend? “Linear” means that the function we are looking for is a straight line Change by 1 unit in one direction results in a change by some constant (m) amount.

When should we fit a regression line? When looking back over the past to see how an observed indicator has changed over time When the plotted values appear to be increasing or decreasing: –a) over the whole period –b) in a linear way, i.e. by the same value each year (e.g. a rate reducing by 100 per year) If we want to calculate the rate of change, or assess whether the increase or decrease is significant Although this is not a recommended method of forecasting future events, it may be used as a rough indicator of likely future changes

Is the change linear? YesNo

Fitting a linear regression line - Example y = 100 – 2x

Fitting a linear regression line The ‘least squares’ method finds the straight line which fits the points most closely Specifically, it finds the line which minimises the squared distances between the points and the line Excel’s LINEST function calculates the intercept and the gradient The chi-squared test assesses the significance of the trend

BUT… The data we most commonly deal with in public health are not usually linear Fitting a linear regression line

What about non-linear trends? In public health we are most commonly dealing with counts, rates or proportions: we routinely transform the data in order to make the transformed data linear and constrain them to be no less than zero We can use a log-transformation for counts or rates, fitting an exponential curve which assumes a constant rate of change, rather than a constant numerical increase or decrease We can use a logit-transformation for proportions (or percentages), which constrains the variable to be between 0 and 1 (or 0% and 100%) Excel’s LOGEST function calculates the intercept and gradient

When you need more complicated models Fractional polynomials - fits curvi-linear line through a set of data points Restricted cubic splines – similar to Fractional polynomials but you can choose number of “knots” (forces the line to be linear in the tails)

Assessing change in trend Segmented regression – fit linear regression line before and after change point; test for step change and/or change in trend Joinpoint regression – lets the model find where the trend changes – each change is called a joinpoint. Free software available to do joinpoint regression

Other considerations Other independent variables to be included in regression models Achieving stability by combining data (eg. years or geographical areas) Assessing goodness of fit

Examples of time trends

A decreasing trend

A decreasing trend?

No apparent change

An increasing trend

Seasonal pattern (plus rising trend)

Change in trend

Step changes

Outlier

Projections / Forecasting

Projections / forecasting How do we set and monitor progress against targets? –Plot historic data on a graph –We need to forecast or predict future data –In some circumstances we can extrapolate from a regression line or curve –There are much better forecasting methods However… –Forecasts are usually wrong! –Accuracy erodes as we go further into the future –A good forecast is more than just a number Includes an accuracy range

Population Projections Population projections for Scotland are available from GROS population/projections/index.html They are available by NHS Board and Council area. The projections look forward 25 years, providing an estimate of the number of males and females in each five- year age group, assuming the continuation of established trends

Prevalence ratio method If we are trying to predict the total number of people with a particular need, this will depend partly on the rate of incidence or prevalence of the issue in question, and partly on the changing size and shape of the population If we already have a population projection we can estimate future numbers by multiplying the extrapolated rate (or current rate if assuming no change) with the population projection

Prevalence ratio method example An RNIB study found that 20% of people aged 75 or over were registered blind or partially sighted If we assume that this rate remains fixed, projections can be obtained by multiplying the population projection for the 75+ age-group by 20% e.g population7,2008,70010,10010,700 Projection in area X Rate of visual impairment20%20%20%20% in 75+ age-group (RNIB) Projected number with1,4401,6201,7402,020 visual impairment in 75+ age-group in area X

Prevalence ratio method - comments Has modest data requirements: even if you only have a single estimate of the rate, you can make a simple projection on the assumption that the rate is fixed Extrapolating trends are OK for a short time into the future as long as the historic data are stable But: The regression line is fitted across the whole of the historic data, and gives equal weight to all points: e.g. the value for last year is given the same weight as one from 20 years ago – it doesn’t give the best estimate of ‘current trends’ We cannot give realistic confidence intervals for future values (‘prediction intervals’ or ‘forecast intervals’)

Age-period-cohort modelling Used widely in cancer epidemiology where cohort effects are important Estimates the underlying age-, period- and cohort-specific trends and models them into the future using a Poisson regression model Programmes available: –“R” open source (free) software – NORDPRED programme available ( Nordpred/Nordpred-software/) –Stata – programmes available from

Other forecasting methods There are a range of methods which are intended for forecasting, eg moving average (ARIMA) methods, autocorrelation methods, Box-Jenkins methods These methods take into account fluctuations from year to year, trends (ie gradual changes over time) and seasonal variations They tend to give greater weight to more recent values They give confidence intervals for forecasts, which tend to get wider as we move further into the future Holt’s Method (which includes a trend component) and Holt-Winters (which adds a seasonal component)

Holt’s method Holt’s exponential smoothing (aka double exponential smoothing) is a moving average method Several statistical packages will do this: –ForecastPro – expensive but very easy to use –Stata –requires code –R – open source (free) software which requires code –Excel – complicated to do If you use Stata, R or Excel, you need to put some effort into optimising the parameters, which requires some expertise and time

Which method to use APC models and Holt method appear to give similar results Holt method has advantage of producing prediction intervals

Further information