reshape_mdb_tx_df: Prepare filtered data frame of treatment indicators for MDB...

View source: R/reshape_mdb_tx_df.R

reshape_mdb_tx_dfR Documentation

Prepare filtered data frame of treatment indicators for MDB formatting

Description

reshape_mdb_tx_df takes the output from make_mdb_tx_df() and creates a gt ready data frame. The transformed data frame retains the most recent quarter and previous year performance. Viral load coverage and viral load suppression percentages are calculated along with TX MMD shares. The resulting table can be passed directly to the mdb_treatment_theme() to create a MDB table. Helper functions format certain columns as svgs to be rendered in the gt call.

Usage

reshape_mdb_tx_df(df)

Arguments

df

dataframe that is the result of running make_mdb_tx_df()

Details

Create a wide formatted and sorted table for treatment indicators

Value

data frame that is pivoted wide for passing to gt() call

See Also

Other data frame munging: collapse_base_tbl(), collapse_vlc_tbl(), make_mdb_df(), make_mdb_tx_df(), reshape_mdb_df()

Examples

## Not run: 
 mdb_df <- make_mdb_tx_df(ou_im, resolve_issues = F)
 mdb_tbl <- reshape_mdb_tx_df(mdb_df)
 
## End(Not run)





USAID-OHA-SI/selfdestructin5 documentation built on Feb. 23, 2025, 5:08 a.m.