I know that this is a very basic question, but I really am having trouble.
I wrote the following code and all I want to do is to read the data correctly, but I cannot find a way to instruct SAS to read the BMI.
There are two things I want to do.
1), Have SAS store the entire number including all the decimals. 2), when printed, I would like to approximate the number to two decimal points.
data HW02EX01;
input Patient 1-2 Weight 5-7 Height 9-10 Age 13-14 BMI 17-26 Smoking $ 29-40 Asthma $ 45-48;
cards;
14 167 70 65 23.9593878 never no
run;
Note: I left only the first observation since the display becomes really ugly and wearisome to edit by hand.
{}icon it will format the code for you to make it legible and cleaner. You see the text below your post to ensure it's correct. You can also visit How to Ask to see recommendations on posting a good question. - Reeza