Skip to content

Commit

Permalink
automatic installation of missing packages
Browse files Browse the repository at this point in the history
  • Loading branch information
onertipaday committed Dec 4, 2012
1 parent 6aabd06 commit 67e7b9b
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions CaseStudy/CaseStudy.Rnw
Expand Up @@ -15,13 +15,13 @@
## this is equivalent to \SweaveOpts{}
opts_chunk$set(fig.path='figure/report-', cache.path='cache/report-', fig.align='center', fig.show='hold', par=TRUE)
options(replace.assign=TRUE, width=68)
library("arrayQualityMetrics") # QC
library("ArrayExpress") # load the data from the internet
library('hgu133plus2.db') # chip annotations
library("gcrma")
library("affyPLM") # boxplots
library("pamr") # classification
library("xtable") # tables
## install and load required packages
my.pkgs <- c("arrayQualityMetrics", "ArrayExpress","hgu133plus2.db","gcrma","affyPLM", "pamr", "xtable")
source("http://bioconductor.org/biocLite.R")
for(i in 1:length(my.pkgs)){
if (my.pkgs[[i]] %in% row.names(installed.packages()) == FALSE) install.packages(my.pkgs[[i]], repos=biocinstallRepos())
require(my.pkgs[[i]], character.only=T)
}
@
%------------------------------------------------------------
\title{{\Large \bf Reproducible Research in High-Throughput Biology:\\ A Case Study}}
Expand Down

0 comments on commit 67e7b9b

Please sign in to comment.