R script to do SAM (Significance Analysis of Microarrays) analysis

SAM is a statistical technique for finding significant genes in a set of microarray experiments.

The input to SAM is gene expression measurements from a set of microarray experiments, as well as a response variable from each experiment. The response variable may be a grouping like untreated, treated [either unpaired or paired], a multiclass grouping (like breast cancer, lymphoma, colon cancer, … ).