Skip to content
Snippets Groups Projects

Develop

Merged Gervaise Henry requested to merge develop into master
Viewing commit 0bb7f937
Show latest version
1 file
+ 1
4
Preferences
File browser
Compare changes
@@ -10,9 +10,6 @@ rm(option_list)
@@ -10,9 +10,6 @@ rm(option_list)
countTable <- read.csv(paste0(opt$repRID,".countData.countTable.csv"), stringsAsFactors=FALSE)
countTable <- read.csv(paste0(opt$repRID,".countData.countTable.csv"), stringsAsFactors=FALSE)
geneID <- read.delim("geneID.tsv", header=FALSE, stringsAsFactors=FALSE)
geneID <- read.delim("geneID.tsv", header=FALSE, stringsAsFactors=FALSE)
Entrez <- read.delim("Entrez.tsv", header=FALSE, stringsAsFactors=FALSE)
Entrez <- read.delim("Entrez.tsv", header=FALSE, stringsAsFactors=FALSE)
convert <- merge(x=Entrez,y=geneID,by.x="V1",by.y="V1",all.x=TRUE)
convert <- data.frame(geneID=countTable$Geneid)
convert <- data.frame(geneID=countTable$Geneid)
convert <- merge(x=convert,y=geneID[,1:2],by.x="geneID",by.y="V2",all.x=TRUE)
convert <- merge(x=convert,y=geneID[,1:2],by.x="geneID",by.y="V2",all.x=TRUE)
@@ -22,6 +19,6 @@ convert <- convert[,-1]
@@ -22,6 +19,6 @@ convert <- convert[,-1]
colnames(convert) <- c("GeneID","EntrezID")
colnames(convert) <- c("GeneID","EntrezID")
convert <- unique(convert)
convert <- unique(convert)
output <- merge(x=convert,y=countTable,by.x="GeneID",by.y="Geneid",all.x=TRUE)
output <- merge(x=convert,y=countTable[,c("Geneid","count","tpm")],by.x="GeneID",by.y="Geneid",all.x=TRUE)
write.table(output,file=paste0(opt$repRID,".tpmTable.csv"),sep=",",row.names=FALSE,quote=FALSE)
write.table(output,file=paste0(opt$repRID,".tpmTable.csv"),sep=",",row.names=FALSE,quote=FALSE)