I have a data set which is the result of a matrix/likert/grid table in a survey. However, I received the data in a strange format and am having trouble re-parsing it into separate columns of data - 1 column per likert prompt. In the sample data, row one has all the right columns of data and the answers are just following it in separate brackets (possible answers are VERY IMPORTANT4, 3, 2, Not AT ALLIMPORTANT1), but as you can see, the following rows have some missing data. Any thoughts on how to get a column of result data per prompt and show missing data where appropriate? I am pretty rusty on string matches and don't really know how to get the missing information to show as missing when not there. Create separate tables and merge things back together? Thanks! Sample Data is here: DATA WORK.Book1;
LENGTH
ID 8
Results $ 145 ;
FORMAT
ID BEST12.
Results $CHAR145. ;
INFORMAT
ID BEST12.
Results $CHAR145. ;
INFILE DATALINES4
DLM='7F'x
MISSOVER
DSD ;
INPUT
ID : BEST32.
Results : $CHAR145. ;
DATALINES4;
1{Spousal considerations}{VERY IMPORTANT4}|{Lifestyle}{VERY IMPORTANT4}|{Hours}{VERY IMPORTANT4}|{Financial considerations }{NOT AT ALLIMPORTANT1}
2{Spousal considerations}{VERY IMPORTANT4}|{Hours}{VERY IMPORTANT4}|{Financial considerations }{NOT AT ALLIMPORTANT1}
3{Spousal considerations}{VERY IMPORTANT4}|{Lifestyle}{3}|{Financial considerations }{NOT AT ALLIMPORTANT1}
;;;;
... View more