📜  seaborn boxplot 多列 - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:54.398000             🧑  作者: Mango

代码示例2
import numpy as np; np.random.seed(42)
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns

df = pd.DataFrame(data = np.random.random(size=(4,4)), columns = ['A','B','C','D'])

sns.boxplot(x="variable", y="value", data=pd.melt(df))

plt.show()