- *同理解决这个转换为年月的日期变量
- clear
- inp id year month
- 1 2010 1
- 1 2010 2
- 1 2010 3
- 1 2010 4
- 1 2010 5
- 1 2010 6
- 1 2010 7
- 1 2010 8
- 1 2010 9
- 1 2010 10
- 1 2010 11
- 1 2010 12
- 2 2011 1
- 2 2011 2
- 2 2011 3
- 2 2011 4
- 2 2011 5
- 2 2011 6
- 2 2011 7
- 2 2011 8
- 2 2011 9
- 2 2011 10
- 2 2011 11
- 2 2011 12
- end
- gen time=ym(year,month)
- format time %tm
- xtset id time