On-line documentation (version 8.x and 9.0)
On-line
documentation is available for versions 8.1, 8.2, and 9.0.
Example SAS programs
SAS programs that have been discussed in lab (or in class) are included
here. You can copy a program to your PC or vincent account by selecting
SAVE AS from the FILE menu in your web browser.
You can copy the file to the SAS program editor window by
selecting Open from the SAS File menu, moving to the appropriate
directory, selecting the program, then clicking OK.
Programs from Lab on 30 Aug 2004
Tomato.sas Data step with infile for
external data, descriptive statistics, plots, 2 sample t-test
Programs from Lab on 20 Sept 2001
Pairedt.sas Code to do a paired t
test in either PROC MEANS or PROC UNIVARIATE. PROC MEANS also
computes confidence interval for mean difference. PROC UNIVARIATE
also computes the nonparametric sign and Wilcoxon signed rank tests.
Programs from Lab on 27 Sept 2004
Bioremed.sas Code to do
nonparametric 2 sample test (Wilcoxon rank sum test).
Transf.sas Code to transform
variables.
Programs from Lab on 11 Oct 2004
diet.sas 1-way ANOVA using PROC
GLM, construction of residual plots
pf.sas Calculate p-values from F
distributions
pt.sas Calculate p-values from t
distributions
Programs from Lab on 18 Oct 2004
diet2.sas Estimates and multiple
comparisons in 1-way ANOVA.
qt.sas Calculate quantiles from a t
distribution
Programs from Lab on 25 Oct 2004
meat.sas Recoding variables, regression
using proc glm, calculating se(prediction), se(predicted obs.), and
confidence limits for predicted values.
Programs from Lab on 15 Nov 2004
brain.sas Multiple linear regression using
PROC GLM and PROC REG.
corn.sas
Calculting polynomial terms. Fitting multiple regression models.
light2.sas
Constructing indicator variables. Fitting multiple regression
models.
N.B. Uses light.txt data file.
anscombe2.sas
Calculating and plotting Cook's distance in proc reg
Note: Uses anscombe.txt data file.
sat.sas
Stepwise and Cp model selection in proc reg
Note: Uses sat.txt data file.
scatterplot.txt Instructions
for plotting a scatterplot matrix.
Programs from Lab on 29 Nov 2004
pygmalion.sas 2 way anova using
Pygmalion data set
collard.sas 2 way anova using
Collard data set
Programs from Lab on 6 Dec 2004
vitc.sas Contingency table analysis,
using Vitamin C data set, included with the program
donner.sas Logistic regression,
using the Donner party data.
Program from class on 10 Dec 2004
readexcel.sas Read an excel
worksheet.
Programs for 'HW' 11 and 12
zinccopper.sas Zinccopper.sas -
for HW 11
worksheet.
iridium.sas Iridium.sas - for HW 11
pique.sas Pique.sas - for HW 12
Need to compute se log OR by hand. Final result (ci for OR) on
output (labelled Case-Control)
Crab problem would use subset of this and Fisher exact test output
Simpson's paradox problem does not need computation