Closed stephanieshong closed 1 week ago
The list of Revenue code within a claim is reviewed within a claim before selecting the visit_concept_id. This prevents us from creating two visits out of one claim.
df_ER = df_rev_codes_long.withColumn( "is_er", F.col("REV_CTR").isin(["0450", "0451", "0452", "0456", "0459", "0981"]) | F.col("TYPE_ADM").isin(["1", "5"]) )
If the claim contains ED revenue code, then the visit created from this claim get assigned to ED->Inpatient visit for the entire claim instead of just Inpatient visit. Be sure to reference all revenue codes that can be found in multiple segments and multiple columns 1-45. And there should only be one visit created for the claim.