data description

This program reads in SAS data set with three types of variables: 1. ID 2. Variable with surrogate exposure, such as ffq. 3. Goldstandard exposure. Goldstandard variables can have repeated measurement. They must be named with ordering number attached. Also they must have the same number of repeated measure for each subject or the program will stop. Please click on "sample data set" to view an example. This is a print out of the sample SAS data set using PROC PRINT. The first variable is ID. The second variable is ffq, a surrogate exposure variable. The 3rd, 4th, 5th, 6th varialbes are goldstandard exposure. They are repeated measure of diet records. These diet records are measured 4 times. So the variables are named vitcno1, vitcno2, vitcno3, and vitcno4. The ordering numbers are attached in the end. To test run this macro, you can copy the program and data set into your computer(Do not copy the first row of variables' names) Read in the data set with SAS and make it a SAS data set. For example, if the data set is saved as dr.dat in Unix environment, you can use the following code to make it a SAS data set named "example": libname out '.'; filename diet 'dr.dat'; data out.example; infile diet lrecl=62; input @1 id 6.0 @14 repvitcn 3.0 @23 vitcno1 7.3 @34 vitcno2 7.3 @45 vitcno3 7.3 @56 vitcno4 7.3; proc print data=out.example noobs; run; After the SAS data set "example" is created, in the end of rankcorr_mmer.sas macro, add: %rankcorr_mmer(data=example, ffq=repvitcn, dr=vitcno, repeated=4); then run it. See "sample output" for results.