Hi all,
I am a beginner on SAS and need your help.
I have a dataset consisting of 100 observations and 3 variables, where these three variables take a value of either 0 or 1 (they are binary). Suppose these three variables are v1, v2, and v3 respectively. I want to update my table considering the following conditions (where the column v4 has been created in advance):
For each single observation, I want to repeat the following action (beginning with the first one until the last observation):
Step1: Copy the row and paste it to the end of the table. If v1 is 0, assign 0 to v4 and jump to the next step. If v1 is 1, assign 1 to v4 and skip all the remaining steps (jump to the next observation).
Step2: Copy the row and paste it to the end of the table. If v2 is 0, assign 0 to v4 and jump to the next step. If v2 is 1, assign 1 to v4 and skip all the remaining steps (jump to the next observation).
Step3: Copy the row and paste it to the end of the table. If v3 is 0, assign 0 to v4 else assign 1 to v4. Jump to the next observation.
After the copy-paste operations, I also want to get rid off the first 100 rows (those rows which constitute the raw data).
I thank you in advance for your support. I hope that I did explain my problem explicitly.
Umut
Message was edited by: umutari
Message was edited by: umutari