SAS数据挖掘

时间:2017-01-25 10:33:52

标签: sas extrapolation

我有一个ID&数据集好/坏指标变量:

ID   Good_Bad
734374  0
4834110 1

我想将1次推断12次为0,这样每0次我就会得到12次1:

ID  Good_Bad
734374  0
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1
4834110 1

&安培;这必须使用SAS完成。任何人都可以帮忙吗?

提前致谢!!

1 个答案:

答案 0 :(得分:0)

data want;

set have;

if      good_bad = 0 then output;
else if good_bad = 1 then do;
  do i = 1 to 12;
    output;
  end;
end;

drop i;
run;
相关问题