Skip to content

Instantly share code, notes, and snippets.

@bkamapantula
Last active April 28, 2016 14:43
Show Gist options
  • Save bkamapantula/3492251ed0f1b1a2490be541fe94355a to your computer and use it in GitHub Desktop.
Save bkamapantula/3492251ed0f1b1a2490be541fe94355a to your computer and use it in GitHub Desktop.
Use GEOquery to get cell type data via GSM accession ID
# requires GEOquery package to be installed
# writes output to stdout
# for more metadata, check the respective classes at http://rileylab.bio.umb.edu/sites/g/files/g1314676/f/201403/GEOquery.pdf
library(GEOquery)
gsm_ids <- c("GSM409307", "GSM1220601", "GSM1120314", "GSM1120315", "GSM1112815", "GSM1112816", "GSM1112817", "GSM1112818", "GSM410808")
for(iter in seq_along(gsm_ids)) {
gds <- getGEO(gsm_ids[iter])
cat(gsm_ids[iter], Meta(gds)$title)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment