Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Demonstrate use of multi-level ipf with Scottish data #78

Open
danlewis85 opened this issue Nov 4, 2024 · 2 comments
Open

Demonstrate use of multi-level ipf with Scottish data #78

danlewis85 opened this issue Nov 4, 2024 · 2 comments
Assignees

Comments

@danlewis85
Copy link

Scotland doesn't publish housing stock ages for small areas. This means we cannot take the same approach we have done in England and Wales.

Scotland does however provide some estimates for housing stock from the Scottish housing condition survey at the local authority level.

As housing age is a significant predictor of energy efficiency and EPCs are biased towards newer properties we want to retain some control over this factor.

A potential solution is to use multi-level iterative proportional fitting, which would constrain the weighting solution to the lsoa-level margins where available and a set of lsoas to their respective la-level housing stock age margin.

The algorithm for doing this multi-level adjustment is only (to our knowledge) publicly implemented in R (package: mlfit), therefore this issue will explore the possibility of using this appraoch via an interface with python (rpy2).

  • demonstrate rpy2 interface.
  • demonstrate reweighting with mlfit.

An alternative would be to redevelop the functionality in python. However, this would take some time as the existing R package is quite mature. Although the algorithm is reasonably straightforward to reproduce, the data reshaping required is quite involved and would likely take time to get right.

@danlewis85 danlewis85 self-assigned this Nov 4, 2024
@danlewis85
Copy link
Author

Looks like mlfit won't actually deliver the reweighting required.

However, I have come across popgen 2.0 which appears to do exactly what I want (as per).

@danlewis85
Copy link
Author

I'm going to look into applying popgen to our problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant