aif360.sklearn.datasets.fetch_meps

aif360.sklearn.datasets.fetch_meps(panel, *, accept_terms=None, data_home=None, cache=True, usecols=['REGION', 'AGE', 'SEX', 'RACE', 'MARRY', 'FTSTU', 'ACTDTY', 'HONRDC', 'RTHLTH', 'MNHLTH', 'HIBPDX', 'CHDDX', 'ANGIDX', 'MIDX', 'OHRTDX', 'STRKDX', 'EMPHDX', 'CHBRON', 'CHOLDX', 'CANCERDX', 'DIABDX', 'JTPAIN', 'ARTHDX', 'ARTHTYPE', 'ASTHDX', 'ADHDADDX', 'PREGNT', 'WLKLIM', 'ACTLIM', 'SOCLIM', 'COGLIM', 'DFHEAR42', 'DFSEE42', 'ADSMOK42', 'PCS42', 'MCS42', 'K6SUM42', 'PHQ242', 'EMPST', 'POVCAT', 'INSCOV'], dropcols=None, numeric_only=False, dropna=True)[source]

Load the Medical Expenditure Panel Survey (MEPS) dataset.

Note

For descriptions of the dataset features, see the data codebook.

Parameters:
  • panel ({19, 20, 21}) – Panel number (only 19, 20, and 21 are currently supported).

  • accept_terms (bool, optional) – Bypass terms prompt. Note: by setting this to True, you acknowledge responsibility for reading and accepting the MEPS usage terms.

  • data_home (string, optional) – Specify another download and cache folder for the datasets. By default all AIF360 datasets are stored in ‘aif360/sklearn/data/raw’ subfolders.

  • cache (bool) – Whether to cache downloaded datasets.

  • usecols (single label or list-like, optional) – Feature column(s) to keep. All others are dropped.

  • dropcols (single label or list-like, optional) – Feature column(s) to drop.

  • numeric_only (bool) – Drop all non-numeric feature columns.

  • dropna (bool) – Drop rows with NAs.

Returns:

namedtuple – Tuple containing X and y for the MEPS dataset accessible by index or name.