This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(oligo) | |
| library(genefilter) | |
| library(RColorBrewer) | |
| library(sva) | |
| library(SpeCond) | |
| basepath <- '/n/HSPH/projects/am_trap' | |
| # | |
| # Get array data |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(lumi) | |
| library(arrayQualityMetrics) | |
| setwd('D:/Storage/My Dropbox/Shared/Mike_LungCancer/') | |
| #setwd('~/Dropbox/Shared/Mike_LungCancer/') | |
| data <- lumiR.batch(c('Batch1_EA10095_20101202_FinalReportNonNormNoBack.txt', | |
| 'Batch2_EA10095_20110729_FinalReportNonNormNoBack_clean.txt'), | |
| sampleInfoFile='SampleDesc.txt') | |
| png('density.png', width=1200, height=800) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(lumi) | |
| library(arrayQualityMetrics) | |
| setwd('~/Dropbox/Shared/Mike_LungCancer/') | |
| data <- lumiR.batch(c('Batch1_EA10095_20101202_FinalReportNonNormNoBack.txt', | |
| 'Batch2_EA10095_20110729_FinalReportNonNormNoBack_clean.txt'), | |
| sampleInfoFile='SampleDesc.txt') | |
| png('density.png', width=1200, height=800) | |
| density(data) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| setwd('/Users/oho/Desktop/Methylation/') | |
| load('probes.450k.rda') | |
| data <- probes.450k | |
| probes <- data$Probe_ID | |
| length(probes) | |
| bedMatrix <- matrix(nrow=length(probes), ncol=6) | |
| for (i in 1:length(probes)) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Plot correlation score in pairs() panel | |
| panel.cor <- function(x, y, digits=2, prefix="", cex.cor) | |
| { | |
| usr <- par("usr"); on.exit(par(usr)) | |
| par(usr = c(0, 1, 0, 1)) | |
| r = (cor(x, y, use="pairwise")) | |
| txt <- format(c(r, 0.123456789), digits=digits)[1] | |
| txt <- paste(prefix, txt, sep="") | |
| if(missing(cex.cor)) cex <- 0.6/strwidth(txt) | |
| text(0.5, 0.5, txt, cex=cex ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| pdf('X_withDuplicates_labels.pdf', width=14, height=14) | |
| plot(mdX, | |
| pch=15, | |
| col=c(rgb(255, 0, 0, 100, maxColorValue=255), | |
| rgb(0, 0, 255, 100, maxColorValue=255))[pData(lumiData)$Sex], | |
| cex=1.2) | |
| text(mdX[, 1], mdX[, 2], labels=pData(lumiData)$SampleLabel, cex=.75) | |
| dev.off() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| arrayQualityMetrics(expressionset=msc.data, | |
| outdir='report_raw', | |
| force=TRUE, | |
| do.logtransform=TRUE) | |
| # Normalize and create second report | |
| msc.eset <- call.exprs(msc.data, "rma"); | |
| arrayQualityMetrics(expressionset=msc.eset, | |
| outdir='report_rma', | |
| force=TRUE, |
NewerOlder