refactoring

This commit is contained in:
frankknoll
2023-02-16 16:11:48 +01:00
parent 54ddc3e47f
commit e7463962c1
5 changed files with 18 additions and 36 deletions

View File

@@ -8,10 +8,3 @@ class SymptomHistogramByBatchcodeTableFactory:
.to_frame(name = 'SYMPTOM_COUNT_BY_VAX_LOT')
.reset_index(level = 'COUNTRY')
[['SYMPTOM_COUNT_BY_VAX_LOT', 'COUNTRY']])
@staticmethod
def createGlobalSymptomHistogramByBatchcodeTable(symptomByBatchcodeTable):
return (symptomByBatchcodeTable
.groupby(symptomByBatchcodeTable.index.names)
['SYMPTOM'].value_counts()
.to_frame(name = 'SYMPTOM_COUNT_BY_VAX_LOT'))