【问题标题】:unable to import pandas in jupyter无法在 jupyter 中导入熊猫
【发布时间】:2021-03-29 07:31:08
【问题描述】:

当我在 jupyter 库中导入 pandas 时,会生成以下内容。

AttributeError                            Traceback (most recent call last)
<ipython-input-24-f869c0f42cc0> in <module>
----> 1 import pandas as pd
      2 import numpy as np
      3 get_ipython().run_line_magic('matplotlib', 'inline')

C:\ProgramData\Anaconda3\lib\site-packages\pandas\__init__.py in <module>
     24 
     25 try:
---> 26     from pandas._libs import (hashtable as _hashtable,
     27                              lib as _lib,
     28                              tslib as _tslib)

pandas\_libs\hashtable_class_helper.pxi in init pandas._libs.hashtable()

AttributeError: type object 'pandas._libs.hashtable.HashTable' has no attribute '__reduce_cython__'

您能帮我解决问题吗?谢谢

【问题讨论】:

    标签: python pandas import anaconda jupyter


    【解决方案1】:

    在代码中使用 pd 代替 pandas。如果您仍然遇到错误,请在问题中也写下您的代码。

    【讨论】:

      猜你喜欢
      • 2017-06-14
      • 2018-08-03
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-12-23
      • 2020-02-10
      • 2016-05-17
      相关资源
      最近更新 更多