即使我將其宣告為黑色,我也無法更改邊框顏色。
fig=plt.figure(figsize=(25, 10), tight_layout = True, edgecolor = 'black')
plt.title('Distribution of Item Type')
plt.xlabel('Item Type')
plt.hist(BigMart_Data_Encoded['Item_Type'],bins = 15)

uj5u.com熱心網友回復:
嘗試在edgecolor函式內部定義引數.hist()而不是圖:
fig=plt.figure(figsize=(25, 10), tight_layout = True)
plt.title('Distribution of Item Type')
plt.xlabel('Item Type')
plt.hist(BigMart_Data_Encoded['Item_Type'],bins=15, edgecolor='black')
轉載請註明出處,本文鏈接:https://www.uj5u.com/qukuanlian/505638.html
標籤:Python matplotlib 数据分析 探索性数据分析
