09-28-2013 10:49 AM
Hi i am trying to estimate a logic model. However my explanotary flag variables both include 0, "." (missing values) and i need to code missing values as "0"
Because i have about 40 variables do you know an esay way yo solve this problem
09-28-2013 11:12 AM
I am not sure what you mean by a "logic model" (perhaps logistic?) nor am I sure what you mean by "flag variables".
Furthermore, coding missing as 0 is often a mistake.
Nevertheless, if you want to do so you can do it in an array (the following code is not tested):
array misszero (*) YOUR LIST OF VARIABLES HERE;
do i = 1 to dim(misszero);
if misszero(i) = . then misszero(i) = 0;