2
我正在尝试编写一个继承pandas'DataFrame
类的类来处理我正在处理的一些自定义数据。继承大熊猫的建筑类DataFrame
class EquityDataFrame(DataFrame):
def __init__(self, *args, **kwargs):
DataFrame.__init__(self, *args, **kwargs)
def myfunc1(self,...)
... # does something
def myfunc2(self, ...)
... # does something
在PyCharm,我得到以下警告该类EquityDataFrame
的名字:
Class EquityDataFrame must implement all abstract methods
This inspection detects when there aren't all abstract properties/methods defined in the subclass
我试着用搜索引擎,但我无法找到此警告的有用信息。有人能帮助我这个警告的含义吗?
类似的将是有益的检查,如果这个错误是特定于pycharm,或者你也可以得到一些相关的错误,如果你尝试运行您的程序独立 – shx2 2015-04-05 16:05:12
无法复制这个问题在Python 2或Python 3下。也许代码的其他部分触发问题,但它不仅仅是'DataFrame'的这个直接的子类。 – 2015-04-05 16:05:13
是的,我在SO上发现了一些关于继承'DataFrame'的更多文章。这可能是由于 – uday 2015-04-05 16:11:13