|
5#

楼主 |
发表于 2011-12-8 00:20:54
|
只看该作者
Re: 求助: 怎样替换变量的值?
Hi Hopewell or fellow SAS users:
Sorry to bother you again.
Right now, I need an update on the code you have provided. That is, in my current small table, the "OLD" column has duplicates, which means, you can see
OLD NEW
1ABC 2FGH
1ABC 3EST
1ABC 4GJU
And I would perfer to create as many seperate observations as the OLD code needs. For example, in the big or source dataset, there is only one observation that contains the code "1ABC", but I want to create three seperate observations for its replacement, which has "2FGH", "3EST" and "4GJU" respectively.
Right now, the code only find a match and replace once, and it only picks the first matched NEW code. I would like to see all the NEW codes show up in the new dataset.
Thank you very much. |
|