再见Excel,这个Python数据可视化库太炫酷了

python将excel表数据可视化,python对excel数据可视化 文件类似如下的形式,# --------2、生成图表并插入到excel---------------# --------2、生成图表并插入到excel---------------# --------2、生成图表并插入到excel---------------# --------1、准备数据并写入excel---------------# --------1、准备数据并写入excel---------------# --------1、准备数据并写入excel--------------- 阅读详情

486c35892f36ed90d15269bac8a7721a.jpeg

来源:网络

f32f2be385f766c71167d9b209525186.jpeg

由下面代码生成 3c793fcd7715feeeb14d41ae9b32637a.png

from chord import Chord

matrix = [
    [0, 5, 6, 4, 7, 4],
    [5, 0, 5, 4, 6, 5],
    [6, 5, 0, 4, 5, 5],
    [4, 4, 4, 0, 5, 5],
    [7, 6, 5, 5, 0, 4],
    [4, 5, 5, 5, 4, 0],
]

names = ["Action", "Adventure", "Comedy", "Drama", "Fantasy", "Thriller"]

# 保存
Chord(matrix, names).to_html("chord-diagram.html")

图形表现力强悍!

Altair概述

Altair是一个用于Python的声明式统计可视化库,基于Vega和Vega-Lite。

Altair提供了一个强大而简洁的可视化语法,使你能够快速建立一个广泛的统计可视化。下面是一个使用Altair API的例子,通过一个交互式散点图快速实现数据集的可视化。

Github:

https://altair-viz.github.io/getting_started/overview.html

30f290e4d4b101bd4e206441151087d7.png

表现强悍

b8afe1cdfd3e7bf9b0ff0030be2a4ab8.png

图形表现力强悍!

import matplotlib.pyplot as plt

# 创建数据
size_of_groups = [12, 11, 3, 30]

# 生成饼图
plt.pie(size_of_groups)

# 在中心添加一个圆, 生成环形图
my_circle = plt.Circle((0, 0), 0.7, color='white')
p = plt.gcf()
p.gca().add_artist(my_circle)

plt.show()

4baf7cb6087af78c11a13c2c312dbd6f.jpeg

image.png

import matplotlib.pyplot as plt
from matplotlib_venn import venn2

# 创建图表
venn2(subsets=(10, 5, 2), set_labels=('Group A', 'Group B'))

# 显示
plt.show()

c45e04bb8b8a6850b64ad949caa84389.jpeg

image.png

import circlify
import matplotlib.pyplot as plt

# 创建画布, 包含一个子图
fig, ax = plt.subplots(figsize=(14, 14))

# 标题
ax.set_title('Repartition of the world population')

# 移除坐标轴
ax.axis('off')

# 人口数据
data = [{'id': 'World', 'datum': 6964195249, 'children': [
              {'id': "North America", 'datum': 450448697,
                  'children': [
                     {'id': "United States", 'datum': 308865000},
                     {'id': "Mexico", 'datum': 107550697},
                     {'id': "Canada", 'datum': 34033000}
                   ]},
              {'id': "South America", 'datum': 278095425,
                  'children': [
                     {'id': "Brazil", 'datum': 192612000},
                     {'id': "Colombia", 'datum': 45349000},
                     {'id': "Argentina", 'datum': 40134425}
                   ]},
              {'id': "Europe", 'datum': 209246682,
                  'children': [
                     {'id': "Germany", 'datum': 81757600},
                     {'id': "France", 'datum': 65447374},
                     {'id': "United Kingdom", 'datum': 62041708}
                   ]},
              {'id': "Africa", 'datum': 311929000,
                  'children': [
                     {'id': "Nigeria", 'datum': 154729000},
                     {'id': "Ethiopia", 'datum': 79221000},
                     {'id': "Egypt", 'datum': 77979000}
                   ]},
              {'id': "Asia", 'datum': 2745929500,
                  'children': [
                     {'id': "China", 'datum': 1336335000},
                     {'id': "India", 'datum': 1178225000},
                     {'id': "Indonesia", 'datum': 231369500}
                   ]}
    ]}]

# 使用circlify()计算, 获取圆的大小, 位置
circles = circlify.circlify(
    data,
    show_enclosure=False,
    target_enclosure=circlify.Circle(x=0, y=0, r=1)
)


lim = max(
    max(
        abs(circle.x) + circle.r,
        abs(circle.y) + circle.r,
    )
    for circle in circles
)
plt.xlim(-lim, lim)
plt.ylim(-lim, lim)

for circle in circles:
    if circle.level != 2:
        continue
    x, y, r = circle
    ax.add_patch(plt.Circle((x, y), r, alpha=0.5, linewidth=2, color="lightblue"))

for circle in circles:
    if circle.level != 3:
        continue
    x, y, r = circle
    label = circle.ex["id"]
    ax.add_patch(plt.Circle((x, y), r, alpha=0.5, linewidth=2, color="#69b3a2"))
    plt.annotate(label, (x, y), ha='center', color="white")

for circle in circles:
    if circle.level != 2:
        continue
    x, y, r = circle
    label = circle.ex["id"]
    plt.annotate(label, (x, y), va='center', ha='center', bbox=dict(facecolor='white', edgecolor='black', boxstyle='round', pad=.5))

plt.show()

59fc736d1daab00b07e9b40a6c9c949e.jpeg

image.png

import folium
import pandas as pd

# 创建地图对象
m = folium.Map(location=[20,0], tiles="OpenStreetMap", zoom_start=2)

# 坐标点数据
data = pd.DataFrame({
   'lon': [-58, 2, 145, 30.32, -4.03, -73.57, 36.82, -38.5],
   'lat': [-34, 49, -38, 59.93, 5.33, 45.52, -1.29, -12.97],
   'name': ['Buenos Aires', 'Paris', 'melbourne', 'St Petersbourg', 'Abidjan', 'Montreal', 'Nairobi', 'Salvador'],
   'value': [10, 12, 40, 70, 23, 43, 100, 43]
}, dtype=str)

# 添加气泡
for i in range(0, len(data)):
    folium.Circle(
      location=[data.iloc[i]['lat'], data.iloc[i]['lon']],
      popup=data.iloc[i]['name'],
      radius=float(data.iloc[i]['value'])*20000,
      color='crimson',
      fill=True,
      fill_color='crimson'
    ).add_to(m)

# 保存
m.save('bubble-map.html')

6ec84ea68b47fcf2621c799efdc939ec.jpeg

image.png

import altair as alt
from vega_datasets import data

boroughs = alt.topo_feature(data.londonBoroughs.url, 'boroughs')
tubelines = alt.topo_feature(data.londonTubeLines.url, 'line')
centroids = data.londonCentroids.url

background = alt.Chart(boroughs).mark_geoshape(
    stroke='white',
    strokeWidth=2
).encode(
    color=alt.value('#eee'),
).properties(
    width=700,
    height=500
)

labels = alt.Chart(centroids).mark_text().encode(
    longitude='cx:Q',
    latitude='cy:Q',
    text='bLabel:N',
    size=alt.value(8),
    opacity=alt.value(0.6)
).transform_calculate(
    "bLabel", "indexof (datum.name,' ') > 0  ? substring(datum.name,0,indexof(datum.name, ' ')) : datum.name"
)

line_scale = alt.Scale(domain=["Bakerloo", "Central", "Circle", "District", "DLR",
                               "Hammersmith & City", "Jubilee", "Metropolitan", "Northern",
                               "Piccadilly", "Victoria", "Waterloo & City"],
                       range=["rgb(137,78,36)", "rgb(220,36,30)", "rgb(255,206,0)",
                              "rgb(1,114,41)", "rgb(0,175,173)", "rgb(215,153,175)",
                              "rgb(106,114,120)", "rgb(114,17,84)", "rgb(0,0,0)",
                              "rgb(0,24,168)", "rgb(0,160,226)", "rgb(106,187,170)"])

lines = alt.Chart(tubelines).mark_geoshape(
    filled=False,
    strokeWidth=2
).encode(
    alt.Color(
        'id:N',
        legend=alt.Legend(
            title=None,
            orient='bottom-right',
            offset=0
        ),
        scale=line_scale
    )
)

background + labels + lines

ccd1b22df31f9c437a6aefaf7aa1f006.jpeg

image.png

import altair as alt
from vega_datasets import data

source = data.disasters.url

alt.Chart(source).mark_circle(
    opacity=0.8,
    stroke='black',
    strokeWidth=1
).encode(
    alt.X('Year:O', axis=alt.Axis(labelAngle=0)),
    alt.Y('Entity:N'),
    alt.Size('Deaths:Q',
        scale=alt.Scale(range=[0, 4000]),
        legend=alt.Legend(title='Annual Global Deaths')
    ),
    alt.Color('Entity:N', legend=None)
).properties(
    width=450,
    height=320
).transform_filter(
    alt.datum.Entity != 'All natural disasters'
)

2641ff8192e01e413880ccefa0f540db.jpeg

image.png

import altair as alt
import pandas as pd

source = pd.DataFrame([
      {'country': 'Great Britain', 'animal': 'cattle'},
      {'country': 'Great Britain', 'animal': 'cattle'},
      {'country': 'Great Britain', 'animal': 'cattle'},
      {'country': 'Great Britain', 'animal': 'pigs'},
      {'country': 'Great Britain', 'animal': 'pigs'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'Great Britain', 'animal': 'sheep'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'cattle'},
      {'country': 'United States', 'animal': 'pigs'},
      {'country': 'United States', 'animal': 'pigs'},
      {'country': 'United States', 'animal': 'pigs'},
      {'country': 'United States', 'animal': 'pigs'},
      {'country': 'United States', 'animal': 'pigs'},
      {'country': 'United States', 'animal': 'pigs'},
      {'country': 'United States', 'animal': 'sheep'},
      {'country': 'United States', 'animal': 'sheep'},
      {'country': 'United States', 'animal': 'sheep'},
      {'country': 'United States', 'animal': 'sheep'},
      {'country': 'United States', 'animal': 'sheep'},
      {'country': 'United States', 'animal': 'sheep'},
      {'country': 'United States', 'animal': 'sheep'}
    ])

domains = ['person', 'cattle', 'pigs', 'sheep']

shape_scale = alt.Scale(
    domain=domains,
    range=[
        'M1.7 -1.7h-0.8c0.3 -0.2 0.6 -0.5 0.6 -0.9c0 -0.6 -0.4 -1 -1 -1c-0.6 0 -1 0.4 -1 1c0 0.4 0.2 0.7 0.6 0.9h-0.8c-0.4 0 -0.7 0.3 -0.7 0.6v1.9c0 0.3 0.3 0.6 0.6 0.6h0.2c0 0 0 0.1 0 0.1v1.9c0 0.3 0.2 0.6 0.3 0.6h1.3c0.2 0 0.3 -0.3 0.3 -0.6v-1.8c0 0 0 -0.1 0 -0.1h0.2c0.3 0 0.6 -0.3 0.6 -0.6v-2c0.2 -0.3 -0.1 -0.6 -0.4 -0.6z',
        'M4 -2c0 0 0.9 -0.7 1.1 -0.8c0.1 -0.1 -0.1 0.5 -0.3 0.7c-0.2 0.2 1.1 1.1 1.1 1.2c0 0.2 -0.2 0.8 -0.4 0.7c-0.1 0 -0.8 -0.3 -1.3 -0.2c-0.5 0.1 -1.3 1.6 -1.5 2c-0.3 0.4 -0.6 0.4 -0.6 0.4c0 0.1 0.3 1.7 0.4 1.8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l-0.3 0c0 0 -0.3 -0.9 -0.3 -1c0 -0.1 -0.1 -0.2 -0.3 -0.2c-0.2 0 -0.3 0.1 -0.4 0.4c0 0.3 -0.2 0.8 -0.2 0.8l-0.3 0l0.3 -1c0 0 0.1 -0.6 -0.2 -0.5c-0.3 0.1 -0.2 -0.1 -0.4 -0.1c-0.2 -0.1 -0.3 0.1 -0.4 0c-0.2 -0.1 -0.3 0.1 -0.5 0c-0.2 -0.1 -0.1 0 -0.3 0.3c-0.2 0.3 -0.4 0.3 -0.4 0.3l0.2 1.1l-0.3 0l-0.2 -1.1c0 0 -0.4 -0.6 -0.5 -0.4c-0.1 0.3 -0.1 0.4 -0.3 0.4c-0.1 -0.1 -0.2 1.1 -0.2 1.1l-0.3 0l0.2 -1.1c0 0 -0.3 -0.1 -0.3 -0.5c0 -0.3 0.1 -0.5 0.1 -0.7c0.1 -0.2 -0.1 -1 -0.2 -1.1c-0.1 -0.2 -0.2 -0.8 -0.2 -0.8c0 0 -0.1 -0.5 0.4 -0.8z'
    ]
)

color_scale = alt.Scale(
    domain=domains,
    range=['rgb(162,160,152)', 'rgb(194,81,64)', 'rgb(93,93,93)', 'rgb(91,131,149)']
)

alt.Chart(source).mark_point(filled=True, opacity=1, size=100).encode(
    alt.X('x:O', axis=None),
    alt.Y('animal:O', axis=None),
    alt.Row('country:N', header=alt.Header(title='')),
    alt.Shape('animal:N', legend=None, scale=shape_scale),
    alt.Color('animal:N', legend=None, scale=color_scale),
).transform_window(
    x='rank()',
    groupby=['country', 'animal']
).properties(width=550, height=140)

8a8fb9e8cd53ced5b99f815f80869529.jpeg

提供丰富的图形代码

7bc9a0c88622aadc39e761e635a09332.png

b6610b8f4f7ab384aeb43d7eda213d2f.png

d5f53009ffff19ae123c9f5c47e77f5f.png

e2258891681e70dcaa097cb82b6cc5b0.png

6cb70c9609f9610ab75db78ebdcc8f47.png

efff3bef1e891b6f458ef3d5814c069b.png

e6ad5e198bd0c21d9a13a922980c3f9a.png

fe0bebed02d7afd3fec1b30d857355bd.png

f48e62143e3b6e05555da3d2928e8db7.png

fd5366dceb2e13409fdfb7553fad9ef3.png

419ba6980a611a131d891e23e7203b01.png

7588501d14f291a6b4d81b9f472f6070.png

41b5f944de6db3afe55c31b405eba9cb.png

1237d5ef2989d61889c27609b874fd9e.png

ac880490a5d124f2e20da172904e46d1.png


 

 

 

 

 

 

 
推荐阅读:
入门: 最全的零基础学Python的问题  | 零基础学了8个月的Python  | 实战项目 |学Python就是这条捷径
干货:爬取豆瓣短评,电影《后来的我们》 | 38年NBA最佳球员分析 |   从万众期待到口碑扑街!唐探3令人失望  | 笑看新倚天屠龙记 | 灯谜答题王 |用Python做个海量小姐姐素描图 |碟中谍这么火,我用机器学习做个迷你推荐系统电影
趣味:弹球游戏  | 九宫格  | 漂亮的花 | 两百行Python《天天酷跑》游戏!
AI: 会做诗的机器人 | 给图片上色 | 预测收入 | 碟中谍这么火,我用机器学习做个迷你推荐系统电影
小工具: Pdf转Word,轻松搞定表格和水印! | 一键把html网页保存为pdf!|  再见PDF提取收费! | 用90行代码打造最强PDF转换器,word、PPT、excel、markdown、html一键转换 | 制作一款钉钉低价机票提示器! |60行代码做了一个语音壁纸切换器天天看小姐姐!|

年度爆款文案

点阅读原文,看B站我的视频!

WindTerm 安装使用教程 WindTerm是一款Github上开源的 SSH 终端工具,它是完全可以比肩MobaXterm工具的。 阅读详情

相关推荐

CentOS 7 常用命令大全

CentOS中Linux命令

m0_63075763的博客 2018

Python实战:用circlify库5分钟搞定不规则圆形布局(附完整代码)

本文详细介绍了如何使用Python的circlify库快速解决Circle Packing(圆形填充)问题,实现不规则圆形的高效紧凑布局。通过从基础安装到实战应用的完整代码示例,帮助开发者轻松应对数据可视化、图形设计等场景中的圆形排列挑战,显著提升开发效率与视觉效果。

dd012的博客 956

【mip-NeRF】使用一组二维图像渲染3D场景视频(mip-NeRF论文复现)

本文对mip-NeRF模型的pytorch实现进行了复现

Ryan2k的博客 1844

[python] 圆形嵌套图Circular Packing

圆形嵌套图Circular Packing 文章目录圆形嵌套图Circular Packing1 具有一级层次的圆形嵌套图绘制1.1 绘图数据与circlify计算1.2 图形绘制1.2.1 基础图形绘制1.2.2 视觉调整1.2.3 圆形之间的空间设置2 具有多级层次的圆形嵌套图绘制2.1 绘图数据与circlify计算2.2 图形绘制3 circlify自带绘图函数4 参考 圆形嵌套图Circular Packing能够将一组组圆形互相嵌套起来,以显示数据的层次关系。本文主要基于circlify实现圆

You and Me 3076

医疗大模型实战——从零构建MedicalGPT全流程解析

本文详细解析了从零构建医疗大模型MedicalGPT的全流程实战。基于Qwen-7B模型与约195万条中文医疗数据,完整复现了增量预训练、监督微调与偏好对齐三大核心环节,并分享了如何在有限硬件资源下实现高效训练与部署,为开发者提供了可复现的医疗AI项目实战指南。

weixin_29193259的博客 553

戴尔笔记本装Ubuntu 20.04,别急着分区!先搞定这个BIOS设置(Intel RST避坑指南)

本文详细介绍了在戴尔笔记本上安装Ubuntu 20.04时遇到的Intel RST技术兼容性问题及解决方案。通过安全切换至AHCI模式,避免安装过程中找不到硬盘的常见问题,并提供双系统分区策略和安装后的优化建议,确保Ubuntu与Windows 10双系统稳定运行。

weixin_31315567的博客 272

python做出的炫酷的可视化,python可视化工具有哪些

在笔者看来,matplotlib的主要任务之一,就是提供一套表示和操作图形对象(主要对象)以及它的内部对象的函数和工具。而且matplotlib不仅可以处理图形,还提供事件处理工具,具有为图形添加动画效果的能力,故而学python什么书比较好。matplotlib就能生成以键盘按键或鼠标移动触发的事件的交互性图表。从逻辑上来讲,matplotlib的整体架构为3层(如下图)。各层之间单向通信,即每一层只能与它的下一层通信,而下层无法与上层通信。1)Bankend层。

2301_81900494的博客 1116

通过CN3口直接控制台达伺服电机A2-M(二)

既然可以通过RS485与伺服驱动器进行通讯,那么就肯定可以控制转速 首先,需要了解下 ‘控制模式及控制命令输入源设定’ 依据以上资料,速度控制模式有两种,S和SZ模式,分别对应模式选择中的02和04,对P1-01的地址0102进行写地址操作即可实现,一开始我使用了S模式,但是这个模式在寸动模式下会自动运转,不符合我控制的要求,后面改用SZ模式,就可以实现零速度。 使用串口工具发送命令:“01 06 01 02 00 04 28 35”即可以实现设置,设置完成后可以手动在伺服驱动器的按键面板上进行确

HKing_evil的博客 6825

python代码图_超好看的弦图,Python一行代码就能做

我的公众号:早起Python============大家好,说起可视化图表,那么弦图(Chord Diagram)一定是颜值担当了,比如在今天这个特殊的日子我们通过使用百度迁徙数据来可视化展示武汉及其周边城市的迁徙数据看上去是不是很酷炫,并且还支持交互,接下来我们就讲解如何使用Python制作这样一张弦图~首先我们先简单介绍一下弦图,弦图主要用于展示多个对象之间的关系,连接圆上任意两点的线段叫做弦...

weixin_42100129的博客 784

【Get深一度】小波分析概念1——紧支撑集是什么意思,通俗解释

最近学到小波,在仿真中也用到了紧支撑函数;紧支撑性越好,说明能量越集中;用最通俗的话来讲,紧支撑是这样的: 对于函数f(x),如果自变量x在 0附近的取值范围内,f(x)能取到 C; 而在此之外,f(x)取值为 0; 那么这个函数f(x)就是紧支

Trey_优快云 的优快云博客 8348

【面试经验】大疆笔试-计算机视觉算法B卷

3、a=np.random.randn(3,3) b=np.random.randn(3,1) ,那么c=a*b的维度应该是:*是元素乘法或者torch.mul,@才是矩阵乘法或者torch.matmul,不会触发广播机制;8、将分辨率降低一半时,精标定内参(fx、fy、cx、cy、k1、k2、k3)焦距、光心、畸变系数将分别变成(fx、fy、cx/2、cy/2、k1、k2、k3),只能搜到光心变成一半,畸变系数不变。12、KLT算法在频闪光源、重复纹理、高速机动、环境照度低的情况下效果显著下降。

litterfinger的博客 1448

再见Excel!这个Python数据可视化库太炫酷了

来源:B座17楼由下面代码生成from chord import Chord matrix = [ [0, 5, 6, 4, 7, 4], [5, 0, 5, 4, 6, 5], [6, 5, 0, 4, 5, 5], [4, 4, 4, 0, 5, 5], [7, 6, 5, 5, 0, 4], [4, 5, 5, 5, 4, 0], ] n...

公众号:Python研究者 180

计算机毕设项目一:基于卷积神经网络、resnet、VGG化妆品分类识别 完整代码数据可直接运行

计算机毕设项目一:基于卷积神经网络、resnet、VGG化妆品分类识别 完整代码数据可直接运行

654

快看看用Python生成Excel炫酷图表,不然你就OUT了

本文对Python 自动化操作Excel并生成图表,做了详细的分析和说明

IT邦德 1万+

老版QQ原生表情gif动态

这是老版的QQ表情,不过全是动态的的,Windows照片查看器是不会动的,可以右击用浏览器打开查看,再说一遍是老版的,只是分享给宁愿用老版也要动态的人。

android 蓝牙通讯demo

android 下蓝牙通讯demo,实现了发现蓝牙,使能蓝牙,通过蓝牙发送消息。

python与excel做数据可视化-Python的Excel操作及数据可视化

Excel表操作python操作excel主要用到xlrd和xlwt这两个库,即xlrd是读excel,xlwt是写excel的库。安装xlrdpip install xlrd简单的表格读取import xlrd#读取表格data=xlrd.open_workbook("table.xlsx")#获取表格的sheetstable=data.sheets()[0]#输出行数量pr...

weixin_37988176的博客 2810

迈瑞BS系列全自动生化分析仪LIS协议接口手册(内含HL7和ASTM)

迈瑞BS系列全自动生化分析仪LIS协议接口手册,内含HL7和ASTM)

python读取excel数据并进行数据可视化_用Python处理Excel的数据,并将之可视化

用Python代码作可视化,如果每次都在代码中以列表的形式来一个一个字符地敲,无异乎浪费时间。我们都知道,在Excel中,数据是以DataFrame(一维的Series是特殊的DataFrame)形式作存储的,而我们在代码中输入的形式一般都是手工地以list的形式来输入。有没有什么快捷的方式呢?今天下午随意上网搜索了一下“Python 柱形图”,就发现了这篇文章(https://www.cnblo...

weixin_39795116的博客 7235

假人有限元模型

假人模型,车辆碰撞假人有限元模型,适合做乘员安全的研究者利用

如何用python做出超炫酷图表?

CDA数据分析研究院原创作品,转载需授权 小编总是被那些玩转数据、利用数据做出超炫酷图表的大佬深深折服,膝盖都不够给他们。进行数据可视化做出超炫图表的软件有很多,今天小编也用数据分析常用的python来演示一下如何做出精彩的数据可视化呈现。 导入相关的库和加载数据 import numpy as np import pandas as ...

weixin_34313182的博客 884

Python:用了这个库,就可以跟 Excel 说再见了

今天分享一个个比 Excel 更好用的 Python 工具,看完后,估计你要跟 Excel 说拜拜了。它就是 MitoMitoMito 是 Python 中的电子表格库。简单易用,如果你能编辑 Excel 文件,你就能编写代码,这是因为,我们在表格中执行的每个操作,Mito 将自动生成对应的 Python 代码。可以跟重复枯燥的操作说再见了。官方文档[1]安装 Mito安...

somenzz的博客 636

python读取excel中数据绘制柱状图_Python的Excel操作及数据可视化

Excel表操作python操作excel主要用到xlrd和xlwt这两个库,即xlrd是读excel,xlwt是写excel的库。安装xlrdpip install xlrd简单的表格读取import xlrd#读取表格data=xlrd.open_workbook("table.xlsx")#获取表格的sheetstable=data.sheets()[0]#输出行数量print(table....

weixin_39634237的博客 4213

向Excel说再见,神级编辑器统一表格与Python

点上方“小詹学Python”,选择“置顶公众号”第一时间获取干货分享!本文转载自:机器之心很多开发者说自从有了 Python/Pandas,Excel 都不怎么用了,用它...

小詹学python的博客 5241

数据可视化(pyecharts库的介绍)

序言:学校里不学python的,没有开设这门课程,暑假买了三本书,都是入门的书籍,连带看b站大佬的视频,就感觉还好,毕竟自己学过c和java了,虽然也都是基础。再来看其它编程语言时,你会发现,语言其实是相通的,许多地方很相似。 被python强大的库所吸引,库的强大带来许多的方便。有人说,只会在python里调用库的猿友们不是大佬,会看源码的猿友们可以称之为大佬。我有一个大佬梦,相信每个人都有,不管是否可以达到预期的目标。我们不管怎样,是否可以学到真正的东西,还是得靠持之以恒。 以上算是对我的一个鼓励吧,我

jgdabc的博客 7832

Python 对Excel数据可视化

# -*- coding: utf8 -*- import pandas as pd import matplotlib.pyplot as plt from matplotlib.pyplot import savefig from pylab import * mpl.rcParams['font.sans-serif'] = ['SimHei'] ...

Luzaofa的博客 1万+

Excel数据可视化:从基础到高级技巧

数据可视化是将数据转换为图形或图表的过程,以便更直观地理解数据模式、趋势和关系。Excel作为常用的电子表格软件,提供了丰富的数据可视化工具和功能。本文将介绍Excel数据可视化的基础到高级技巧,帮助读者更好地理解和应用数据可视化。

极客代码 6374

python与excel做数据可视化-用Python进行数据可视化的10种方法

原标题:用Python进行数据可视化的10种方法2015-11-19 关于转载授权大数据文摘作品,欢迎个人转发朋友圈,自媒体、媒体、机构转载务必申请授权,后台留言“机构名称+转载”,申请过授权的不必再次申请,只要按约定转载即可,但文末需放置大数据文摘二维码。编译|黄念校对|丁一引言艺术之美根植于其所传达的信息。有时候,现实并非我们所看到或感知到的。达芬奇(Da Vinci)和毕加索(Picasso...

weixin_37988176的博客 8598

Python爬虫以及数据可视化分析

Python爬虫以及数据可视化分析之B站动漫排行榜信息爬取分析 简书地址:https://www.jianshu.com/u/40ac87350697 简单几步,通过Python对B站番剧排行数据进行爬取,并进行可视化分析 源码文件可以参考Github上传的项目:https://github.com/Lemon-Sheep/Py/tree/master 下面,我们开始吧! PS: 作为Python爬虫初学者,如有不正确的地方,望各路大神不吝赐教[抱拳] 本项目将会对B站番剧排行的数据进行网页信息爬取以及

三明治的博客 9万+
上一篇: 为啥程序员下班后只关显示器从不关电脑?看看各大网站的答案~
下一篇: 卧槽!爱了爱了,这几个Python装逼神器一定要收藏好!
菜鸟学Python
博客等级 码龄9年 8062粉丝 571原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值