Hi,
I calculated means (Y) for originator B. However, I would like to create a variable Z that fills in this mean (from originator B) for A and C as well within each month. My data looks as like this:
I think I need to use the egen command, but I can't figure out how to fill in the missing value.
Any help is appreciated!
I calculated means (Y) for originator B. However, I would like to create a variable Z that fills in this mean (from originator B) for A and C as well within each month. My data looks as like this:
Originator | Date | Y | Z |
A | 2005m1 | . | 1.5 |
B | 2005m1 | 1.5 | 1.5 |
C | 2005m1 | . | 1.5 |
A | 2006m1 | . | 1 |
B | 2006m1 | 1 | 1 |
C | 2006m1 | . | 1 |
Any help is appreciated!
Comment