当前位置: 首页>>代码示例>>Python>>正文


Python errors.AbstractMethodError方法代码示例

本文整理汇总了Python中pandas.errors.AbstractMethodError方法的典型用法代码示例。如果您正苦于以下问题:Python errors.AbstractMethodError方法的具体用法?Python errors.AbstractMethodError怎么用?Python errors.AbstractMethodError使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在pandas.errors的用法示例。


在下文中一共展示了errors.AbstractMethodError方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: _from_sequence

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _from_sequence(cls, scalars, dtype=None, copy=False):
        """
        Construct a new ExtensionArray from a sequence of scalars.

        Parameters
        ----------
        scalars : Sequence
            Each element will be an instance of the scalar type for this
            array, ``cls.dtype.type``.
        dtype : dtype, optional
            Construct for this particular dtype. This should be a Dtype
            compatible with the ExtensionArray.
        copy : boolean, default False
            If True, copy the underlying data.

        Returns
        -------
        ExtensionArray
        """
        raise AbstractMethodError(cls) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:22,代码来源:base.py

示例2: _from_sequence_of_strings

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _from_sequence_of_strings(cls, strings, dtype=None, copy=False):
        """Construct a new ExtensionArray from a sequence of strings.

        .. versionadded:: 0.24.0

        Parameters
        ----------
        strings : Sequence
            Each element will be an instance of the scalar type for this
            array, ``cls.dtype.type``.
        dtype : dtype, optional
            Construct for this particular dtype. This should be a Dtype
            compatible with the ExtensionArray.
        copy : boolean, default False
            If True, copy the underlying data.

        Returns
        -------
        ExtensionArray

        """
        raise AbstractMethodError(cls) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:24,代码来源:base.py

示例3: _from_factorized

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _from_factorized(cls, values, original):
        """
        Reconstruct an ExtensionArray after factorization.

        Parameters
        ----------
        values : ndarray
            An integer ndarray with the factorized values.
        original : ExtensionArray
            The original ExtensionArray that factorize was called on.

        See Also
        --------
        pandas.factorize
        ExtensionArray.factorize
        """
        raise AbstractMethodError(cls)

    # ------------------------------------------------------------------------
    # Must be a Sequence
    # ------------------------------------------------------------------------ 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:23,代码来源:base.py

示例4: isna

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def isna(self):
        # type: () -> Union[ExtensionArray, np.ndarray]
        """
        A 1-D array indicating if each value is missing.

        Returns
        -------
        na_values : Union[np.ndarray, ExtensionArray]
            In most cases, this should return a NumPy ndarray. For
            exceptional cases like ``SparseArray``, where returning
            an ndarray would be expensive, an ExtensionArray may be
            returned.

        Notes
        -----
        If returning an ExtensionArray, then

        * ``na_values._is_boolean`` should be True
        * `na_values` should implement :func:`ExtensionArray._reduce`
        * ``na_values.any`` and ``na_values.all`` should be implemented
        """
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:24,代码来源:base.py

示例5: copy

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def copy(self, deep=False):
        # type: (bool) -> ExtensionArray
        """
        Return a copy of the array.

        Parameters
        ----------
        deep : bool, default False
            Also copy the underlying data backing this array.

        Returns
        -------
        ExtensionArray
        """
        raise AbstractMethodError(self)

    # ------------------------------------------------------------------------
    # Printing
    # ------------------------------------------------------------------------ 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:21,代码来源:base.py

示例6: _parse_tbody_tr

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _parse_tbody_tr(self, table):
        """
        Return the list of tbody row elements from the parsed table element.

        HTML5 table bodies consist of either 0 or more <tbody> elements (which
        only contain <tr> elements) or 0 or more <tr> elements. This method
        checks for both structures.

        Parameters
        ----------
        table : a table element that contains row elements.

        Returns
        -------
        list of node-like
            These are the <tr> row elements of a table.
        """
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:20,代码来源:html.py

示例7: _parse_tables

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _parse_tables(self, doc, match, attrs):
        """
        Return all tables from the parsed DOM.

        Parameters
        ----------
        doc : the DOM from which to parse the table element.

        match : str or regular expression
            The text to search for in the DOM tree.

        attrs : dict
            A dictionary of table attributes that can be used to disambiguate
            multiple tables on a page.

        Raises
        ------
        ValueError : `match` does not match any text in the document.

        Returns
        -------
        list of node-like
            HTML <table> elements to be parsed into raw data.
        """
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:27,代码来源:html.py

示例8: _equals_tag

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _equals_tag(self, obj, tag):
        """
        Return whether an individual DOM node matches a tag

        Parameters
        ----------
        obj : node-like
            A DOM node.

        tag : str
            Tag name to be checked for equality.

        Returns
        -------
        boolean
            Whether `obj`'s tag name is `tag`
        """
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:20,代码来源:html.py

示例9: _concat_same_type

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _concat_same_type(cls, to_concat):
        # type: (Sequence[ExtensionArray]) -> ExtensionArray
        """Concatenate multiple array

        Parameters
        ----------
        to_concat : sequence of this type

        Returns
        -------
        ExtensionArray
        """
        raise AbstractMethodError(cls)

    # The _can_hold_na attribute is set to True so that pandas internals
    # will use the ExtensionDtype.na_value as the NA value in operations
    # such as take(), reindex(), shift(), etc.  In addition, those results
    # will then be of the ExtensionArray subclass rather than an array
    # of objects 
开发者ID:birforce,项目名称:vnpy_crypto,代码行数:21,代码来源:base.py

示例10: _make_plot

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _make_plot(self):
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:4,代码来源:_core.py

示例11: _apply

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _apply(self, n, other):
        """
        Handle specific apply logic for child classes.
        """
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:7,代码来源:offsets.py

示例12: _get_roll

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _get_roll(self, i, before_day_of_month, after_day_of_month):
        """
        Return an array with the correct n for each date in i.

        The roll array is based on the fact that i gets rolled back to
        the first day of the month.
        """
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:10,代码来源:offsets.py

示例13: _apply_index_days

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def _apply_index_days(self, i, roll):
        """
        Apply the correct day for each date in i.
        """
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:7,代码来源:offsets.py

示例14: classmethod

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def classmethod(cls):
        raise AbstractMethodError(cls, methodtype='classmethod') 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:4,代码来源:test_errors.py

示例15: method

# 需要导入模块: from pandas import errors [as 别名]
# 或者: from pandas.errors import AbstractMethodError [as 别名]
def method(self):
        raise AbstractMethodError(self) 
开发者ID:Frank-qlu,项目名称:recruit,代码行数:4,代码来源:test_errors.py


注:本文中的pandas.errors.AbstractMethodError方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。