Presentation is loading. Please wait.

Presentation is loading. Please wait.

Curve fitting Session 2. Method background Disability rates are strongly linked to age However HSE disability rates for single years of age are unstable.

Similar presentations


Presentation on theme: "Curve fitting Session 2. Method background Disability rates are strongly linked to age However HSE disability rates for single years of age are unstable."— Presentation transcript:

1 Curve fitting Session 2

2 Method background Disability rates are strongly linked to age However HSE disability rates for single years of age are unstable We can fit a curve to the disability schedule to smooth the fluctuations Model rates (national or regional)*local population totals

3 Source: HSE 2001 Mobility disability – England (Males)

4 Personal care disability – England (males) Source: HSE 2001

5 Dealing with sampling variability Rates are unreliable particularly where sample sizes are small Smooth fluctuations by fitting a curve

6 Dealing with sampling variability

7 What function? Lots of choices Quadratic (y=b 0 +b 1 x+b 2 x 3 +b 3 x 3 Exponential functions Estimation of mortality schedules Statistics Canada use an exponential curve to model disability schedules in Canadian territories

8 Exponential curve Where: D(x)= the proportion of people with a disability at age x

9 Practical structure Task 3 – Fit an exponential curve to (England) mobility schedules (with and without weights). Uses saved data from task 2 Task 4 – Fit curves to regional mobility schedules Task 5 – Use your model rates to calculate the number of people with a mobility disability in six districts. (Data provided)

10 Fitting a curve in stata nl (MO_OBS_RT=exp({a}+{b}*age)) predict pred_MO_UK

11 Exponential curve – parameter estimates (males) Confidence interval a -4.4 -4.79 -4.09 b 0.04 0.05

12 Mobility disability schedules – observed and modelled

13 Analytic weights Stata treats the rates at each age as being equally reliable. Can use weights to relax this assumption If we assume our rates stem from a binomial process then: Where p x = proportion with a disability at age x and N x equals the number of people sampled at age x.

14 Calculating weights (task 3) Re-open the HSE data Re-calculate age specific rates (MO_OBS_RT) (as in task 2) egen mobilitycount=count(MO_OBS_RT), by (age sex) gen mobilityweight=mobilitycount/(MO_OBS_RT*(1*MO_OBS_RT))

15 Model weights – mobility disability

16 Fitting a curve in stata nl (MO_OBS_RT=exp({a}+{b}*age)) [aweight=mobilityweight] predict pred_MO_UK

17 Mobility schedules – observed and modelled (with weights) Better fit at youngest ages

18 Task 4 – regional curves Open HSE data Drop institutional residents (no gora) Are differences in regional rates of mobility disability significant? (1.4.2-1.4.3)

19 Task 4 - regional curves Calculate regional schedules of mobility disability rates by sex age gora: egen MO_num=total(mobility_w) by sex age gora: egen MO_denom=total(count_w) gen MO_OBS_RT=MO_num/MO_denom

20 Task 4 – regional curves Weights are the same as used for national data (task 3) Regional age patterns of weight very unstable After calculating regional rates and weights: Duplicates drop age sex gora, force

21 Task 4 –regional curves nl (MO_OBS_RT=exp({a}+{b}*age)) if sex==1&gora==1 [aweight=mobilityweight] predict pred_MO1_M nl (MO_OBS_RT=exp({a}+{b}*age)) if sex==1&gora==2 [aweight=mobilityweight] predict pred_MO2_M Fit curves for each region (males and females)

22

23 Task 5 Aim - generate district estimates of the numbers of people with mobility disabilities Practical 1 task 5 dataset.dta a row for each single year of age (10, 11,….84,88) for males and females in each of the six districts Contains the national and regional model rates from tasks 3 and 4 Population counts


Download ppt "Curve fitting Session 2. Method background Disability rates are strongly linked to age However HSE disability rates for single years of age are unstable."

Similar presentations


Ads by Google