Added add_maternal_deaths() to classify sibling deaths as pregnancy-related or maternal based on DHS coding variables (sib.died.pregnant, sib.time.delivery.death, sib.died.accident).
Added aggregate_maternal_estimates() to aggregate age-specific maternal mortality estimates across age groups using the respondent age distribution as weights. Supports both point estimates and bootstrap confidence intervals.
Added get_ego_age_distn() (internal) to compute the weighted age distribution of survey respondents, used as the reference population for aggregation.
Improved bootstrap performance in sibling_estimator() via matrix multiplication (get_boot_ests_matrix()), replacing a wide-dataframe approach and achieving substantial speed-ups for large bootstrap replicate counts.
Bug fixes
Fixed a grouping bug in sibling_estimator() that caused an error (Column '.ego.id' doesn't exist) when using dplyr < 1.1.0. The summarise(across(...)) calls introduced in the dplyr 1.0 migration were missing .groups = "drop", so the result remained grouped by .ego.id. This residual grouping propagated through pivot_wider and purrr::map_dfr into get_ec_reports(), where a subsequent group_by(across(all_of(...))) failed because dplyr 1.0.x evaluates across() in a mutate context that cannot select already-active grouping variables. Fixed by adding .groups = "drop" to the summarise in occ.exp() and get_ec_reports(), and adding a defensive ungroup() before the group_by in get_ec_reports(). The bug was most visible when calling sibling_estimator() inside purrr::imap_dfr().
Fixed aggregate_maternal_estimates(), which was accidentally referencing package-level example objects (ex.ego, ex.sib) instead of the ego.dat and sib.dat arguments passed by the caller.
Fixed attributes.to.long(): replaced defunct dplyr::select_(), mutate_(), and filter_() (deprecated in dplyr 0.7, now defunct) with modern equivalents (select(all_of(...)), mutate(across(...)), filter()). Removed lazyeval from package Imports. This unblocked devtools::build(), which was failing when building vignettes.
Tests
Added regression tests for the grouping bug: sibling_estimator() returns ungrouped data frames, works correctly when called via purrr::imap_dfr(), and handles column names containing dots (e.g. ego.id, sib.id).