У меня проблемы с построением фрейма данных и круга рядом друг с другом. Мой код:
import matplotlib.pyplot as plt
import pandas as pd
import numpy as np
df = \
pd.DataFrame({'data': {'Performance': "[None, ' bps']Performance cannot be calculated",
'Basket Switch Cost': '400000 bps / 4000',
'10\\% VWAP Switch Cost': '0 bps / 0',
'Portfolio Expense Ratio': 'Savings of None bps / None',
'Common Items': '523 Items \\& 53% by Weight',
'Starting \\& Ending Security Count': '611 / 611',
'Largest Sector Exposure Difference': '0% Increase in Information Technology',
'Common Inception Date': '2011-03-24'}})
ax = plt.subplot2grid((1,3), (0,0), colspan=2)
circle = plt.Circle((0.0,0.0),radius=0.75, fc='r')
plt.gca().add_patch(circle)
ax.axis('scaled')
ax2 = plt.subplot2grid((1,3), (0,2))
font_size=10
bbox=[0, 0, 1, 1]
ax2.axis('off')
mpl_table = ax2.table(cellText = df.values, rowLabels = df.index,
bbox=bbox, colLabels=df.columns)
mpl_table.auto_set_font_size(False)
mpl_table.set_fontsize(font_size)
plt.tight_layout()
Как видите, две фигуры перекрывают друг друга, и я хочу, чтобы в первом столбце были кружок, а во втором - фрейм данных. Как я могу выполнить sh это?