ONSdigital / SDG_11.2.1

Analysis for the UN Sustainable Development Goal 11.2.1
https://onsdigital.github.io/SDG_11.2.1/
Apache License 2.0
5 stars 7 forks source link

Research how to make mid-year age calculations in NI data #392

Closed jwestw closed 1 year ago

jwestw commented 1 year ago

We will be calculating for disability and sex in #391 using a method similar to #97 however this will not work for age as ages are increasing year on year.

Research a method for carrying out mid-year population estimates for age.

paigeh-fsa commented 1 year ago

Firstly, I'm going to look at how the proportion changes in E&W as we have data for this for each year including non-census years, and see if it is consistent upon multiple years or not. It may be a simple calculation if this is the case.

paigeh-fsa commented 1 year ago

I've taken a look between 2019 and 2020 data in E&W to see if it's consistent across multiple years.

I did this by taking the 2019 and 2020 age dataframes for all output areas in E&W.

Then did the following calculation:

$\frac{\text{2020 output area age}}{\text{2020 output area pop}} - \frac{\text{2019 output area age}}{\text{2019 output area pop}} * 100$

This will give us the proportion of people who are aged X (e.g. age 0) for 2020 minus the proportion of people who are aged X for 2019. Multiplying this by 100 will give us the percentage difference between the two.

I then calculated the mean and median across all output areas. This will show how different the proportions of people, on average for all local authorities, are for a particular age.

image

Looking at the mean and median percentage difference, all are actually below 0.1%. If we could achieve this same calculation over a wider gap of years (e.g. how different are the proportions of people from 2011 to 2020 for example) and it had a low percentage difference, we could say that these proportions are relatively consistent and we can use proportions to calculate ages.

Appreciate this is not for E&W and not NI, so we can also look at the differences in proportions between censuses for NI too.

jwestw commented 1 year ago

Could you look at more years to verify that the proportion stays consistent over a longer period? Could you add some details of your investigation into our WIP/Google methodology document?

paigeh-fsa commented 1 year ago

I've also taken a look at the difference in ages between 2001 NI census and 2011 census. One caveat with this work is 2001 census only gives age population estimates over a 5 year age span, so I had to convert these into 5 year age groups for 2011. Also, some of the later year groups have dashes in 2001 census to denote low numbers and for disclosure control. I have assumed these to be zero for ease. We must also be mindful that Northern Ireland have a change between output areas and small areas between 2001 and 2011. A lookup table was used with a 1:1 correspondence however this isn't always 100% the correct geometries and may affect the output.

Using a similar calculation to before:

$(\frac{\text{2011 NI small area age}}{\text{2011 NI small area pop}} - \frac{\text{2001 NI small area age}}{\text{2001 NI smal larea pop}}) * 100$

This allows us to get the percentage difference between the two censuses.

image

This shows that, at least for the younger year groups, the average difference across all small areas is around 1-2%. Considering this is currently in age groups, I would say this is good. The highest average difference is 6%, which is still relatively small.

@jwestw do you think, at least for now, we can use this method to calculate the age groups, using their proportions from the 2011 census to calculate the number of people across all age groups for all small areas?

If this method is agreed, I can write it up in our methodology document.