import pandas as pd
import numpy as np
from pandas.plotting import table
import matplotlib.pyplot as plt
from pandas.plotting import scatter_matrix
df = pd.DataFrame(np.random.randn(10, 4),
columns=["a", "b", "c", "d"])
#导入数据
fig,ax=plt.subplots(1,1,figsize=(10,5))
table(ax,
np.round(df.describe(), 2),
loc="best",
colWidths=[0.2, 0.2, 0.2,0.2])
df.plot(ax=ax,
ylim=(-2,4),
legend=None);