how should i write codes about this? Thank you!
Posted: Wed Oct 29, 2008 11:22 am
I have a series called A (a1, a2, a3). What i want to do is if (a1,a2,a3) >65 then a new series B = (a1-65,a2-65,a3-65) generated; if not then the observation which below 65 returns 0. For example, A = (98,68,63) then B = (98-65,68-65,0)=(33,3,0). My code is like
if A > 65 then genr B = A-65 else genr B =0 endif
The problem is that the series B is always generated as all 0. Could you please suggest me how should I change this code? Thank you!!!
if A > 65 then genr B = A-65 else genr B =0 endif
The problem is that the series B is always generated as all 0. Could you please suggest me how should I change this code? Thank you!!!