Cascading Replace in Stata

Опубликовано: 19 Май 2026
на канале: Econometrics, Causality, and Coding with Dr. HK
4,457
27

Sorry for the audio cut at the beginning! This is a very useful trick that I use all the time whenever I am doing data editing in Stata. A nice aspect of this I forgot to mention is that it works with strings, which egen doesn't do. Imagine you had some string variable, like First_Name, that was present only for January observations, but missing for others. You could use this trick to fill in the data so you know that the person's name is Frank in February and March, too.