Bases: BaseAnnotationCombiner
Merges GEO and SRA combined annotation BSONs into a single sample-level DB.
Example:
>>> combiner = SampleCombiner()
>>> combiner.combine().clean().save(SAMPLE_COMBINED_BSON)
combine(geo_bson=GEO_COMBINED_BSON, sra_bson=SRA_COMBINED_BSON, db_path=OMICIDX_DB)
¶
Load and merge the GEO and SRA combined BSONs, then enrich accession IDs.
For each GSM present in either source, annotation-type dicts are
merged by source name. accession_ids dicts are unioned, with
the SRA entry taking precedence for conflicting keys. Accession IDs
are then enriched from OmicIDX with series, platform, srx,
and srp fields.
| Parameters: |
|
|---|
| Returns: |
|
|---|
enrich_annotations(all_gsm, db_path)
¶
Enrich sample annotations with organism, series IDs, platform IDs, and cross-references to SRA. Updates annotations in-place.
| Parameters: |
|
|---|
| Returns: |
|
|---|