Announcement

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

  • Keeping a variable value over years that was only answered once

    Hi there,

    I'm investing the role of house prices on happiness and am using a FE model. The data has the original house price the respondent bought the house at in the year they bought it (e.g. $1m in 2006), however I want to generate a variable that keeps that $1m figure until/if they buy a new house

    For example:
    2006 = $1m (original entry in dataset)
    2007 = $1m
    2008 = $1.5m (original entry in dataset = bought new house)
    2009 = $1.5m
    2010 = $1.5m

    Right now my data set would record $1m, . , $1.5m, . , .

    I would really appreciate any help possible on creating this variable. Thank you in advance!

  • #2
    FAQ https://www.stata.com/support/faqs/d...issing-values/

    Comment


    • #3
      Thank you!

      Comment

      Working...
      X