Mercurial > repos > testtool > get_geo
comparison getMETAdata/getMETAdata.R @ 38:608ab56a90d0 draft
Uploaded
author | testtool |
---|---|
date | Mon, 14 Aug 2017 09:21:07 -0400 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
37:ec7a1f7f9a94 | 38:608ab56a90d0 |
---|---|
1 require("data.table", quietly = TRUE) | |
2 require("GEOquery", quietly = TRUE) | |
3 | |
4 | |
5 options(warn = -1) | |
6 options("download.file.method"="wget") | |
7 args <- commandArgs(trailingOnly = TRUE) | |
8 GSMTable = args[1] | |
9 MetaTable = args[2] | |
10 | |
11 TAB = fread(GSMTable) | |
12 | |
13 | |
14 if (is.null(TAB)) { | |
15 stop("Must specify input files") | |
16 } else { | |
17 options(download.file.method.GEOquery = "wget") | |
18 | |
19 | |
20 GEODataTable <- getGEO(TAB$ID[1], getGPL = FALSE) | |
21 MetaData <- data.frame(Meta(GEODataTable)) | |
22 | |
23 write.table(MetaData, MetaTable, row.names = FALSE, sep = "\t") | |
24 } | |
25 |