shap.datasets.linnerud

shap.datasets.linnerud(n_points=None)

Return the Linnerud dataset in a convenient package for multi-target regression.

Parameters:
n_pointsint, optional

Number of data points to include. Default is None, including all data points.

Returns:
Tuple of pandas DataFrames containing the feature matrix and the target variables.

Notes

  • The Linnerud dataset contains physiological and exercise data for 20 individuals.0

  • The feature matrix includes three exercise variables: Chins, Situps, Jumps.

  • The target variables include three physiological measurements: Weight, Waist, Pulse.

More details: https://scikit-learn.org/stable/modules/generated/sklearn.datasets.load_linnerud.html

Examples

To get the feature matrix and target variables:

features, targets = shap.datasets.linnerud()

To get a subset of the data:

subset_features, subset_targets = shap.datasets.linnerud(n_points=100)