日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程语言 > python >内容正文

python

python 三维图直方图_Python | 阶梯直方图

發布時間:2025/3/11 python 33 豆豆
生活随笔 收集整理的這篇文章主要介紹了 python 三维图直方图_Python | 阶梯直方图 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

python 三維圖直方圖

A histogram is a graphical technique or a type of data representation using bars of different heights such that each bar group's numbers into ranges (bins or buckets). Taller the bar higher the data falls in that bin. A Histogram is one of the most used techniques in data visualization and therefore, matplotlib has provided a function matplotlib.pyplot.hist() for plotting histograms. Step histogram is a type of histogram in which Bars are not filled with color, instead only the edge is the representation of Histogram. It is in a form of steps of stairs and therefore it is known as step histogram.

直方圖是使用不同高度的條形圖的圖形技術或一種數據表示形式,以使每個條形圖組的數字都位于范圍內(箱或桶)。 數據落入該容器的欄越高,該欄越高。 直方圖是數據可視化中最常用的技術之一,因此,matplotlib提供了一個函數matplotlib.pyplot.hist()來繪制直方圖。 階梯直方圖是直方圖的一種類型,其中條形圖未填充顏色,而是僅邊緣表示直方圖。 它采用階梯的形式,因此稱為階梯直方圖。

The following example illustrates the implementation and use of the Step Histogram Plot.

以下示例說明了“階梯直方圖”的實現和使用。

步進直方圖的Python代碼 (Python code for step histogram plot)

import matplotlib.pyplot as plt import numpy as np# random data generation mu, sigma = 100, 15 x = mu + sigma * np.random.randn(10000)# Histogram of the Data plt.figure() plt.hist(x, 25, histtype='step') plt.xlabel('Smarts') plt.ylabel('Probability') plt.title('Step Histogram') plt.show()plt.figure() plt.hist(x, 15, density=1, histtype='step') plt.xlabel('Smarts') plt.ylabel('Probability') plt.title('Step Histogram : No. of Bins = 15') plt.show()plt.figure() plt.hist(x, 10, density=1, edgecolor='purple', linewidth=2.0, histtype='step') plt.xlabel('Smarts') plt.ylabel('Probability') plt.title('Step Histogram : Edge Width = 2.0') plt.show()

Output:

輸出:

Output is as figure

翻譯自: https://www.includehelp.com/python/step-histogram-plot.aspx

python 三維圖直方圖

總結

以上是生活随笔為你收集整理的python 三维图直方图_Python | 阶梯直方图的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。