Skip to content

Commit

Permalink
Fix bitwise AND operation error
Browse files Browse the repository at this point in the history
  • Loading branch information
vahid-ahmadi committed Jan 14, 2025
1 parent a2f73d2 commit a061877
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,9 @@ def formula(benunit, period, parameters):
"incompatibilities_childcare_eligible", period
).astype(bool)

is_eligible = (
meets_age_condition & meets_income_condition & childcare_eligible
# Combine conditions using logical AND
is_eligible = np.logical_and.reduce(
[meets_age_condition, meets_income_condition, childcare_eligible]
)

# Calculate per-child amounts at the person level
Expand Down

0 comments on commit a061877

Please sign in to comment.