shap.datasets.corrgroups60
- shap.datasets.corrgroups60(n_points: int = 1000) tuple[DataFrame, ndarray]
Correlated Groups (60 features)
A synthetic dataset consisting of 60 features with tight correlations among distinct groups of features.
- Parameters:
- n_pointsint, optional
Number of data points to generate. Default is 1,000.
- Returns:
- Xpd.DataFrame
The feature data matrix
- ynp.ndarray
The target variables
Notes
The dataset is generated with known correlations among distinct groups of features.
Each feature is a unit variance Gaussian random variable centred around 0.
The labels are generated based on a linear function of the features with added random noise.
Examples
data, target = shap.datasets.corrgroups60()