python - 如何'AttributeError:模块'pandas.core.common'没有属性'_dict_keys_to_ordered_list''
问题描述
错误:模块“pandas.core.common”没有属性“_dict_keys_to_ordered_list”
嗨,我认为我的熊猫有一些问题,这是以前从未发生过的。我重新安装了它,但没有修复它......有谁知道如何解决它?Thx!我在下面附上了我的所有代码,并认为这可能是我的 Python(3.0 版本)中的环境问题
import numpy as np
import pandas as pd
#import statsmodels.api as sm #Method1
import statsmodels.formula.api as smf #Method2
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
import requests #get requests
from bs4 import BeautifulSoup
def get_onepage(url):
strhtml=requests.get(url)
soup=BeautifulSoup(strhtml.text,'lxml')
#data = soup.select('#main>div>div.mtop.firstMod.clearfix>div.centerBox>ul.newsList>li>a')
journal = soup.select('div.sc_content > div.sc_info > span:nth-of-type(2) > a')
citecount = soup.select('div.sc_content > div.sc_info > span:nth-of-type(3) > a')
titlename = soup.select(' div.sc_content > h3 > a')
authorname = soup.select('div.sc_content > div.sc_info > span:nth-of-type(1)')
yearpublish = soup.select('div.sc_content > div.sc_info > span.sc_time')
解决方案
推荐阅读
- android - 如何根据 Spinner 的选中项接收数据并显示记录。在 Android 的 SQLITE DatabaseHelper.java
- python - 损失函数中的Tensorflow Slicing
- javascript - 如何在 Google 表格中使用带有自定义 HTML 表单的引导日期时间选择器?
- node.js - Firebase 身份验证导致云函数返回空
- asynchronous - Elixir 等待多个并发任务中的任何一个完成
- reactjs - 我们可以将 Typescript 类分配给 React 中功能组件的 useState 字段吗?
- python - requests.get 没有获取所有标签。我需要那个页面的表格
- java - 随机数组
- javascript - 如何将拖放存储到本地存储
- python - TypeError:必须是 str,而不是 mail.mass_mailing.list