This example calls the qms2
macro. The macro is told to read IBD information from the
file dump-sas.ibd, which would have been
generated using pre-sas.sh. The
phenotype information is in the file
genehunter.ped. The data used has 10
markers, and codes missing phenotypes as
-99. The imported data will be saved into
the library mydata and the dataset
ibdphen.
Example 6-1. myanalyzer.sas
libname mydata '$HOME/sas/qms2';
options mautosource sasautos=('$HOME/sas/qms2');
options mprint;
%qms2(data=mydata.ibdphen,
output=mydata.qtl,
infce=1,
infout=mydata.inf);
proc print data=mydata.qtl;
proc print data=mydata.inf;
|
- The option
mautosource tells the SAS
Software to look in the specified directory for any
macros which are referenced in the script. In this
example, the directory sas/qms2/ under the
user's home directory will be searched.
- The option mprint will print out
the SAS Software statements which are created from the
macro. This option isn't necessary for normal usage,
but it makes debugging much easier.
- A SAS Software macro is called using the convention
%macroname(macroargument1,macroargument2);.
For readability, the macro arguments can be split
across lines.
- This line will print out the results of the
QTL analyses. The qms2 macro
does not print anything out on its own. Under
normal SAS Software conventions, the output will be
saved in, for this example, the file
myanalyzer.lst.
After running this SAS Software script two permanent datasets
will be created. That dataset can then be used with the
qms2 macro or other SAS Software scripts.