随笔分类 -  利用python进行数据分析

摘要:1.背景主题、字体大小设置 安装Jupyter主题: pip install jupyterthemes -i https://mirrors.aliyun.com/pypi/simple 然后,更新Jupyter主题: pip install --upgrade jupyterthemes 查看可 阅读全文
posted @ 2019-03-28 09:51 耐烦不急 阅读(23283) 评论(0) 推荐(1) 编辑
摘要:import pandas as pd dood_inf0=pd.read_csv("C:\\Users\\Administrator\\Desktop\\food_info.csv") dood_inf1=pd.read_csv(r"C:\Users\Administrator\Desktop\food_info.csv") dood_inf2=pd.read_csv("C:/Users/Ad... 阅读全文
posted @ 2018-06-05 15:56 耐烦不急 阅读(2953) 评论(0) 推荐(0) 编辑
摘要:Array 结果: array([[1, 2, 3, 4], [5, 6, 7, 8]]) 结果: array([[ 0., 0., 0.], [ 0., 0., 0.]]) 结果: array([[ 1., 0., 0., 0., 0.], [ 0., 1., 0., 0., 0.], [ 0., 阅读全文
posted @ 2018-04-19 00:13 耐烦不急 阅读(396) 评论(0) 推荐(0) 编辑
摘要:数据获取 结果: 结果: 结果: 结果: <class 'pandas.core.frame.DataFrame'> DatetimeIndex: 789 entries, 2014-09-19 to 2017-11-03 Data columns (total 6 columns): Open 7 阅读全文
posted @ 2018-04-17 15:44 耐烦不急 阅读(627) 评论(0) 推荐(0) 编辑
摘要:Series的简单运算 结果: A 1 B 2 C 3 dtype: int64 结果: B 4 C 5 D 6 E 7 dtype: int64 结果: A NaN B 6.0 C 8.0 D NaN E NaN dtype: float64 DataFrame的简单数学计算 结果: 结果: BJ 阅读全文
posted @ 2018-04-13 22:41 耐烦不急 阅读(1783) 评论(0) 推荐(0) 编辑
摘要:Seaborn-Powerful Matplotlib Extension seaborn实现直方图和密度图 结果: (array([ 1., 4., 19., 88., 231., 256., 218., 140., 37., 6.]), array([-3.98123959, -3.280904 阅读全文
posted @ 2018-04-11 17:42 耐烦不急 阅读(618) 评论(0) 推荐(0) 编辑
摘要:结果: [<matplotlib.lines.Line2D at 0x8b0ae48>] 结果: [<matplotlib.lines.Line2D at 0x9d45940>] 结果: [<matplotlib.lines.Line2D at 0x9e28518>] 结果: [<matplotli 阅读全文
posted @ 2018-04-11 09:14 耐烦不急 阅读(456) 评论(0) 推荐(0) 编辑
摘要:# 0 1 # 1 2 # 2 3 # 3 4 # dtype: int64 # 0 5 # 1 6 # 2 7 # 3 8 # 4 9 # dtype: int32 # 5 1 # 6 3 # 7 9 # dtype: int64 Series与DataFrame: pandas中的DateFra 阅读全文
posted @ 2018-04-05 17:47 耐烦不急 阅读(979) 评论(0) 推荐(0) 编辑
摘要:结果: Python (英国发音:/ˈpaɪθən/ 美国发音:/ˈpaɪθɑːn/), 是一种面向对象的解释型计算机程序设计语言,由荷兰人Guido van Rossum于1989年发明,第一个公开发行版发行于1991年。 Python是纯粹的自由软件, 源代码和解释器CPython遵循 GPL( 阅读全文
posted @ 2018-03-23 10:40 耐烦不急 阅读(1619) 评论(0) 推荐(0) 编辑
摘要:Series 结果: 0 10 1 11 2 12 3 13 4 14 5 15 6 16 7 17 8 18 9 19 dtype: int64 [10 11 12 13 14 15 16 17 18 19] <class 'numpy.ndarray'> 结果: 0 10 1 11 2 12 3 阅读全文
posted @ 2018-03-21 21:58 耐烦不急 阅读(983) 评论(0) 推荐(0) 编辑
摘要:结果: [[0.11959428 0.52816495 0.31736705] [0.75400637 0.26683732 0.54080784]] <class 'numpy.ndarray'> 结果: 维度个数 2 各维度大小 (2, 3) 数据类型 float64 补充: ndarray,N 阅读全文
posted @ 2018-03-18 22:11 耐烦不急 阅读(947) 评论(0) 推荐(0) 编辑
摘要:首先下载:anaconda3.x 下载方式:百度搜索 清华镜像anaconda https://mirrors.tuna.tsinghua.edu.cn/help/anaconda/(进入第一个下载链接,选择最新版本) 启动:jupyter notebook(在线编辑,适合演示),支持Markdow 阅读全文
posted @ 2018-03-18 20:47 耐烦不急 阅读(299) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示