OutliersDataCheck.
validate
Checks if there are any outliers in a dataframe by using IQR to determine column anomalies. Column with anomalies are considered to contain outliers.
X (pd.DataFrame) – Features
y – Ignored.
A set of columns that may have outlier data.
dict
Example
>>> df = pd.DataFrame({ ... 'x': [1, 2, 3, 4, 5], ... 'y': [6, 7, 8, 9, 10], ... 'z': [-1, -2, -3, -1201, -4] ... }) >>> outliers_check = OutliersDataCheck() >>> assert outliers_check.validate(df) == {"warnings": [{"message": "Column(s) 'z' are likely to have outlier data.", "data_check_name": "OutliersDataCheck", "level": "warning", "code": "HAS_OUTLIERS", "details": {"columns": ["z"]}}], "errors": []}