Valuebai

Results 15 issues of Valuebai

1、使用数据集: 数据集下载地址:豆瓣评论数据集:https://github.com/Computing-Intelligence/datasource/raw/master/movie_comments.csv 2、用pandas打开,查看原始数据类型,是object的,直接使用douban['star'].mean()会报错 3、网上搜索尝试了多种方法,但是没用 4、最后在文章https://juejin.im/post/5acc36e66fb9a028d043c2a5中,进行修改,在打开csv文档时加入converters={'star': lambda x: pd.to_numeric(x, errors='coerce')} ``` import pandas as pd douban = pd.read_csv('.\input\movie_comments.csv',converters={'star': lambda x: pd.to_numeric(x, errors='coerce')}) douban.info() douban.dtypes douban.fillna(0, inplace = True) douban.info() douban.dtypes douban.isnull().describe()...

``` # 解决matplotlib显示中文问题 # 仅适用于Windows plt.rcParams['font.sans-serif'] = ['SimHei'] # 指定默认字体 plt.rcParams['axes.unicode_minus'] = False # 解决保存图像是负号'-'显示为方块的问题 # MacOS请参考 http://wenda.chinahadoop.cn/question/5304 修改字体配置 ```

1、根据教程进行安装https://blog.csdn.net/qq_40304090/article/details/88594813 For windows users: 1.install Graphviz 2.Add Graphviz path to PATH variable 3.Restart PyCharm or other compiler. 2、重启pycharm再跑代码!!!

简单有效的笨办法: 把大文件夹直接exculeded,这样不影响,被excluded的文件还是可以在程序中用。 ![image](https://user-images.githubusercontent.com/9695113/70597132-825fbe80-1c22-11ea-9c4c-e825f172bbbf.png) 【原文】https://blog.csdn.net/hhhhhyyyyy8/article/details/83314940

解决方案:参考下面的文章 pycharm把.py文件识别成.text文件 https://blog.csdn.net/baiyu9821179/article/details/53926168 ```python 解决方案: File->Settings->Editor->File Types 里面找到text,然后在text里找到这个文件名,删除就可以了 在jupyter book中添加下面的*.ipynb文件 ``` ![image](https://user-images.githubusercontent.com/9695113/65034027-d1c28580-d978-11e9-9316-563234e7089e.png)