guma44 / GEOparse

Python library to access Gene Expression Omnibus Database (GEO)
BSD 3-Clause "New" or "Revised" License
141 stars 51 forks source link

Automatically generate pheno data #6

Closed guma44 closed 7 years ago

guma44 commented 8 years ago

Now in order to generate the phenotypic data like in the pData from GEOquery one should do following:

pheno_data = {}
for gsm_name, gsm in gse.gsms.iteritems():
    print gsm_name, gsm
    pheno_data[gsm_name] = {key: value[0] for key, value in gsm.metadata.iteritems()}
pheno_data = pd.DataFrame(pheno_data).T

This should be a function.

guma44 commented 7 years ago

A property called phenotype_data was added in the version 0.1.9.