Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Creating per capita income from IPUMS ACS dataset across multiple years

    I'm working on ACS dataset which doesn't provide number of population in 50 states across different years. But, for each person the income is given.

    I need to create per capita income from here and my best guess is by using egen command. Is it like the following

    bysort statefip year: egen tot_inc = total(income)
    bysort statefip year: egen tot_pop =total(statefip==?) [ I'm confused here since I don't know how to figure out the total population in ACS dataset for a particular state in a given year ]

    gen per_cap_inc = tot_inc/tot_pop

    I know how to figure out the per capita income for 50 states in multiple years , the thing is I'm having trouble how to find the total number of population in my dataset for a particular state in a given year ?

    Please put your valuable input if you have any experience with IPUMS ACS data or you have a hunch on how to find total respondents from a particular state in. a given year from any dataset ?

  • #2
    Just remember that this is survey data. Your tot_inc variable isn't weighted. Pay attention to the pwgtp variable (think of it as the number of persons). So your pop variable would be

    Code:
    bysort statefip year: egen tot_pop =total(pwgtp)
    And your income would be something more along the lines of

    Code:
    gen inc = income * pwgtp
    bysort statefip year: egen tot_inc = total(inc)
    
    gen per_cap_inc = tot_inc/tot_pop
    It's always good to see if you can reproduce the ACS (American Community Survey) estimates to make sure you're on the right track. For example, I've downloaded the 2019 1-year sample for Rhode Island and according to the figures on the Census website the population is 1,059,361 (as shown here https://data.census.gov/cedsci/profile?g=0400000US44)

    Code:
    qui import delimited using "/Users/justinniakamal/Desktop/psam_p44.csv", clear
    egen tot_pop = total(pwgtp)
    di tot_pop[1]
    1059361
    Your estimates usually won't excatly match what's reported (especially income), but should be in the neighborhood. Hope this helps.
    Last edited by Justin Niakamal; 19 Apr 2021, 11:57.

    Comment


    • #3
      I really can't express my gratitude how insightful this feedback was for my understanding. Much appreciated for such kind and well detailed information !

      Comment

      Working...
      X