Skip to content

Commit

Permalink
all merged
Browse files Browse the repository at this point in the history
  • Loading branch information
Matiss Ozols committed Dec 13, 2024
2 parents 005e4f0 + 158ab1e commit 2ba636a
Show file tree
Hide file tree
Showing 6 changed files with 228 additions and 143 deletions.
10 changes: 8 additions & 2 deletions bin/cohort_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
# Split Donor Report by cohort


Donor_Report2 = Donor_Report.set_index('Pool_ID.Donor_Id')
Donor_Report2 = Donor_Report.set_index(Donor_Report['Pool_ID.Donor_Id'])

try:
Donor_Report2.insert(0,'Vacutainer ID','NONE')
Expand Down Expand Up @@ -176,7 +176,10 @@ def Generate_Report(GT_MATCH_CONFIDENT,pan):
return Total_Report

GT_MATCH['final_panel']=GT_MATCH['final_panel'].str.replace("_[1-9][0-9]*$","", regex=True)
GT_MATCH['donor_gt'] = GT_MATCH['donor_gt'].astype(str)
GT_MATCH['donor_gt original'] = GT_MATCH['donor_gt'].astype(str)
for confident_panel in set(GT_MATCH['final_panel']):
print(confident_panel)
if (confident_panel!='NONE' and confident_panel!='GT_cell_lines'):
print(confident_panel)
pan=confident_panel.replace('GT_','')
Expand Down Expand Up @@ -214,7 +217,10 @@ def Generate_Report(GT_MATCH_CONFIDENT,pan):
Donor_Report2.loc[Total_Report2.index,'viability']=Total_Report2.loc[Total_Report2.index,'viability']
Donor_Report2.loc[Total_Report2.index,'Match Expected']=Total_Report2.loc[Total_Report2.index,'Match Expected']
Donor_Report2.loc[Total_Report2.index,'Sequencing time']=Total_Report2.loc[Total_Report2.index,'Sequencing time']
Donor_Report2 = Donor_Report2.reset_index().set_index('Pool ID')
try:
Donor_Report2 = Donor_Report2.reset_index().set_index('Pool ID')
except:
Donor_Report2 = Donor_Report2.set_index('Pool ID')

GT_MATCH2 = GT_MATCH.set_index('pool')
GT_MATCH2=GT_MATCH2[['Emergency_ids expected','Good_ids expected']]
Expand Down
Loading

0 comments on commit 2ba636a

Please sign in to comment.