w****r 发帖数: 186 | 1 wait online, please advise!
Use such syntax to assign format, all other worked, except those code
starting with V.
Can anybody help on this?
proc format;
value $angiof
"00.61", "00.62", "00.66", "36.03", "39.50", "v45.82" ="angio ";
Thanks! | d******9 发帖数: 404 | 2 It works very well. Why did u say it does not work???
proc format;
value $angiof
"00.61", "00.62", "00.66", "36.03", "39.50", "v45.82" ="angio ";
run;
data A;
input A S $;
format S $angiof.;
cards;
1 00.61
2 00.66
3 36.03
4 39.50
5 v45.82
;
run;
proc print;
run;
SAS Ourput:
Obs A S
1 1 angio
2 2 angio
3 3 angio
4 4 angio
5 5 angio | w****r 发帖数: 186 | 3 Thanks so much for checking!
I actually messed the lower case/upper case. It shpould be V45.82 based on
my data.
Many thanks!
【在 d******9 的大作中提到】 : It works very well. Why did u say it does not work??? : proc format; : value $angiof : "00.61", "00.62", "00.66", "36.03", "39.50", "v45.82" ="angio "; : run; : data A; : input A S $; : format S $angiof.; : cards; : 1 00.61
|
|