我想了解如何讀取SAS格式不正確的數據。波紋管是片段,也是我嘗試的開始。我也試着做一個if語句,但不知道如何爲每一行聲明一個格式。例如: if _N_ then [format for this line goes here]; data prob2;
length name $ 8 ;
infile rawdata(Group2.txt) truncover;
input Code Nam
我認爲這很容易,但我無法擺脫困境。 我有一組名爲變量,然後日期變量和一個值變量: GROUP Date Value
A 1-1-2010 1
A 2-1-2010 2
A 3-1-2010 3
A 4-1-2010 4
B 1-1-2010 5
B 2-1-2010 6
B 3-1-2010 7
B 4-1-2010 8
C 1-1-2010 9
C 2-1-2010 10