* open a new program (editor) and paste "est_srs" and "srs" macros into the new program and then run just the macros (they will then be ready to use for SRS). Then use separate program for your analysis; * url for data in INFILE; filename uspop url 'http://webpages.uidaho.edu/~renaes/Data/uspop.csv'; data uspop; length State $ 15; * first row to read in is row 3 since row1 has headers and row2 is the whole US; infile uspop firstobs=3 dlm=','; input State $ TotalPop Section Pop18_24 PopGE18 Pop15_44 PopGE65 PopGE85 PctPov; run; proc print; run; proc means sum; var pop18_24; run; * random sample selection; %srs(frame=uspop,npop=50,n=16,sample=uspop_srs,seed=59373); proc print data = uspop_srs; run; * calculate the mean, variance, and bound from SRS; %est_srs(sample=uspop_srs,npop=50,response=Pop18_24,param=total);