pandas
code_tailor
这个作者很懒,什么都没留下…
展开
-
Seaborn | Distribution Plots
https://www.geeksforgeeks.org/seaborn-distribution-plots/?ref=gcse Difficulty Level : Medium Last Updated : 26 Aug, 2019 Seaborn is a Python data visualization library based on Matplotlib. It provides a high-level interface for drawing attractive and infor原创 2022-03-18 21:40:04 · 363 阅读 · 0 评论 -
Histograms
https://mode.com/example-gallery/python_histogram/原创 2022-03-18 10:54:41 · 88 阅读 · 0 评论 -
Working with excel files using Pandas
https://www.geeksforgeeks.org/working-with-excel-files-using-pandas/原创 2022-03-09 16:32:53 · 615 阅读 · 0 评论 -
DataFrame 修改列名
先建立一个DataFrame import pandas as pd a = pd.DataFrame({‘A’:[1,2,3], ‘B’:[4,5,6], ‘C’:[7,8,9]}) a A B C 0 1 4 7 1 2 5 8 2 3 6 9 方法一:直接赋值 a.columns = [‘a’,‘b’,‘c’] a a b c 0 1 4 7 1 2 5 8 2 3 6 9 一次要更新所有的列名 方法二:字典映射 a.rename(co原创 2022-03-04 10:20:14 · 953 阅读 · 0 评论 -
熊猫 分组
import pandas as pd import numpy as np group by : split apply combine dic_gpa = {‘class’:[‘A’,‘B’,‘A’,‘B’], ‘sname’:[‘tom’,‘kite’,‘tom’,‘hanmeimei’], ‘math’:(np.random.rand(4)*100).round(), ‘english’:(np.random.rand(4)*100).round() } df = pd.DataFrame(dic_原创 2022-03-02 17:22:28 · 845 阅读 · 0 评论 -
pandas errors Pattern matched multiple keys
Set some Pandas options as you like old version #pd.set_option(‘max_columns’, 40) #pd.set_option(‘max_rows’, 30) new version pd.options.display.max_rows=30 pd.options.display.max_columns=40原创 2022-03-02 10:36:40 · 2070 阅读 · 0 评论