fetch_midwest_survey#

skrub.datasets.fetch_midwest_survey(data_home=None)[source]#

Fetches the midwest survey dataset (classification), available at skrub-data/skrub-data-files

Survey to know if people self-identify as Midwesterners. Size on disk: 504KB.

Parameters:
data_homestr or path-like, default=None

The directory where to download and unzip the files.

Returns:
bunchBunch

A dictionary-like object with the following keys:

midwest_surveyDataFrame of shape (2494, 29)

The dataframe.

XDataFrame of shape (2494, 28)

Features, i.e. the dataframe without the target labels.

yDataFrame of shape (2494, 1)

Target labels,

metadatadict

A dictionary containing the name, description, source and target.

pathstr

The path to the midwest survey CSV file.

Examples

>>> from skrub.datasets import fetch_midwest_survey
>>> data = fetch_midwest_survey()
>>> print(data.keys())
dict_keys(['path', 'metadata', 'metadata_path', 'midwest_survey',
  'midwest_survey_path', 'X', 'y'])