***最近经常用到这个就记录记录
一般的笨办法
gen float health = 1 if a15 == 5
replace health = 2 if a15 == 4
replace health = 3 if a15 == 3
replace health = 4 if a15 == 2
replace health = 5 if a15 == 1
sum health
label var health "健康状况1-5从差到好"
****简单方法来两个
replace health=6-var
***recode var (之前变量值= 之后变量值)
recode a15 (1=5) (2=4) (1=1) (3=3) (4=2) (5=1) , gen (health)
label var health "健康状况1-5从差到好"