diff options
author | Lei Yan | 2014-02-04 11:00:38 -0600 |
---|---|---|
committer | Lei Yan | 2014-02-04 11:00:38 -0600 |
commit | 2c6abd47b78bea42423aa45f417897525f63f8a2 (patch) | |
tree | 65b62439685bdecae2ef99d14757a51e021b7147 /wqflask/maintenance | |
parent | 91491d2f9918603f8270026b2b7a14d53d5f9037 (diff) | |
download | genenetwork2-2c6abd47b78bea42423aa45f417897525f63f8a2.tar.gz |
On branch master
Diffstat (limited to 'wqflask/maintenance')
-rw-r--r-- | wqflask/maintenance/dataset/probesets.py | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/wqflask/maintenance/dataset/probesets.py b/wqflask/maintenance/dataset/probesets.py index fbe54108..2c755203 100644 --- a/wqflask/maintenance/dataset/probesets.py +++ b/wqflask/maintenance/dataset/probesets.py @@ -15,7 +15,7 @@ def get_probesetxref(probesetfreezeid): def get_probeset(probesetid): cursor = utilities.get_cursor() sql = """ - SELECT * + SELECT ProbeSet.`Id`, ProbeSet.`Name`, ProbeSet.`Symbol`, ProbeSet.`description`, ProbeSet.`Probe_Target_Description`, ProbeSet.`Chr`, ProbeSet.`Mb` FROM ProbeSet WHERE ProbeSet.`Id`=%s """ @@ -57,4 +57,15 @@ def get_probesetxref_inbredsetid(locus, inbredsetid): cursor.execute(sql, (inbredsetid, locus)) return cursor.fetchall() -print get_probesetxref_inbredsetid(locus="rs3663871", inbredsetid=1)
\ No newline at end of file +def get_normalized_probeset(locus, inbredsetid): + normalized_probesets = [] + probesetxrefs = get_probesetxref_inbredsetid(locus, inbredsetid) + for probesetxref in probesetxrefs: + normalized_probeset = [] + probesetid = probesetxref[0] + probeset = get_probeset(probesetid) + normalized_probeset.append(probeset) + normalized_probesets.append(normalized_probeset) + print normalized_probesets + +get_normalized_probeset(locus="rs3663871", inbredsetid=1) |