This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
howtos:toolcoding:using_a_relative_propensity [2010/11/12 21:10] shona.weldon |
howtos:toolcoding:using_a_relative_propensity [2010/11/25 13:11] shona.weldon |
||
---|---|---|---|
Line 19: | Line 19: | ||
!Equation A: | !Equation A: | ||
- | local peoplePerHouseholdEst[uss,usdt,th] = households[uss,usdt,th] * peoplePerHousehold[usdt] | + | local populationEst[uss,th] = sum (households[uss,usdt,th] * relPopPersPerHH[usdt]; dim=usdt) |
!Equation B: | !Equation B: | ||
- | peoplePerHousehold[uss,usdt,th] = population[uss,th] / peoplePerHouseholdEst[uss,usdt,th] * relPopPersPerHH[usdt] | + | peoplePerHousehold[uss,usdt,th] = population[uss,th] / populationEst[uss,th] * relPopPersPerHH[usdt] |
===== Check your above equation through symbol substitution algebra ===== | ===== Check your above equation through symbol substitution algebra ===== | ||
You know your identity : | You know your identity : | ||
- | population[uss,th] = households[uss,usdt,th] * peoplePerHousehold[uss,usdt,th] | + | population[uss,th] = sum (households[uss,usdt,th] * peoplePerHousehold[uss,usdt,th]; dim=usdt) |
substituting from your final math Equation B for personPerHousehold: | substituting from your final math Equation B for personPerHousehold: | ||
- | population[uss,th] = households[uss,usdt,th] * population[uss,th] / peoplePerHouseholdEst[uss,usdt,th] * relPopPersPerHH[usdt] | + | population[uss,th] = households[uss,usdt,th] * population[uss,th] / populationEst[uss,usdt,th] * relPopPersPerHH[usdt] |
reordering: | reordering: | ||
population[uss,th] = households[uss,usdt,th] * relPopPersPerHH[usdt] * population[uss,th] / peoplePerHouseholdEst[uss,usdt,th] | population[uss,th] = households[uss,usdt,th] * relPopPersPerHH[usdt] * population[uss,th] / peoplePerHouseholdEst[uss,usdt,th] |