pandera.api.dataframe.model_components.dataframe_check

pandera.api.dataframe.model_components.dataframe_check(_fn=None, **check_kwargs)[source]

定义 DataFrameModel 的检查方法用于数据框。

0.5.0 中的新功能

在DataFrameModel上装饰一个方法,表明它应该用于验证DataFrame。该方法将被转换为类方法。因此,它的签名必须以cls开头,后面跟着常规检查参数。有关更多信息,请参见用户指南

Parameters:

check_kwargs – 转发给检查的关键字参数。

Return type:

Callable[[Union[classmethod, Callable[…, Any]]], classmethod]