diff getGSMdata/getGSMdata.R @ 26:ac5415190777 draft

Uploaded
author testtool
date Wed, 15 Feb 2017 10:21:18 -0500
parents 5e1d49abfc99
children 0051ff360c64
line wrap: on
line diff
--- a/getGSMdata/getGSMdata.R	Mon Feb 06 10:31:24 2017 -0500
+++ b/getGSMdata/getGSMdata.R	Wed Feb 15 10:21:18 2017 -0500
@@ -1,9 +1,12 @@
 require("rentrez", quietly = TRUE)
 
 args <- commandArgs(trailingOnly = TRUE)
+
 GSE = args[1]
 GSMTable = args[2]
 
+
+
 search1 <- entrez_search(db = "gds", term = GSE, retmax = 1)
 
 rec2 <- entrez_summary(db = "gds",
@@ -16,5 +19,8 @@
 colnames(samples)[which(names(samples) == "accession")] <- "ID"
 colnames(samples)[which(names(samples) == "title")] <-  "Phenotype"
 
-write.table(samples, GSMTable, row.names = FALSE, sep = "\t",quote = FALSE)
+samples$Phenotype<-gsub("\\s", "",samples$Phenotype) 
 
+write.table(samples, GSMTable, row.names = FALSE,quote=FALSE,sep="\t")
+
+