changeset 38:3277861975eb draft

Uploaded
author proteomisc
date Sat, 16 Dec 2023 12:23:16 +0000
parents 10acbb8418d7
children e80d3d455db7
files preprocess_datasets/Agilent_One_Color_Preprocessing_Functions.R
diffstat 1 files changed, 18 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/preprocess_datasets/Agilent_One_Color_Preprocessing_Functions.R	Sat Dec 16 12:23:16 2023 +0000
@@ -0,0 +1,18 @@
+AgilentOneColorPreprocessingFunction<- function(data,methodBC,methodNBA)
+{
+MA <<- backgroundCorrect(data, method=methodBC ,offset = 2) 
+rownames(MA$E)=MA$genes$ProbeName
+MA<-MA[rm.na(rownames(MA$E)),]
+MAb <<-suppressWarnings(suppressMessages(normalizeBetweenArrays(MA, method=methodNBA)))
+data_mt<-NaRV.omit(as.data.frame(MAb$E))
+MAb$E=(data_mt)
+MAb$genes=MAb$genes[(MAb$genes$ProbeName %in% rownames(MAb$E)),]
+MAb$E=MAb$E[rownames(MAb$E) %in% MAb$genes$ProbeName,]
+MA.avg <-suppressWarnings(suppressMessages(avereps(MAb, ID=rownames(MAb$E))))
+data_matrix=NaRV.omit(MA.avg$E)
+colnames(data_matrix)<-designo$sample
+write.table(format(data_matrix, justify="right"),sep="\t", quote=FALSE,
+            row.names=T, col.names=T,file="Matrix.Data.tsv")
+
+return(list(dataNBA=MA.avg,dataBG=MA,matrix_data=as.matrix(MA.avg$E),symbol=MA.avg$genes$GeneName))
+}