Spaces:
Runtime error
Runtime error
Upload tool.py
Browse files
tool.py
CHANGED
@@ -408,8 +408,8 @@ def plot_stock_data(stock_data: pd.DataFrame, ax: Optional[plt.Axes] = None, fig
|
|
408 |
plt.xlabel(x_name, fontproperties=font_prop,fontsize=18)
|
409 |
plt.ylabel(f'{index_name}', fontproperties=font_prop,fontsize=16)
|
410 |
ax.set_title(title_name , fontproperties=font_prop,fontsize=16)
|
411 |
-
plt.legend() # 显示图例
|
412 |
-
fig = plt.gcf(
|
413 |
fig.set_size_inches(18, 12)
|
414 |
|
415 |
return ax
|
|
|
408 |
plt.xlabel(x_name, fontproperties=font_prop,fontsize=18)
|
409 |
plt.ylabel(f'{index_name}', fontproperties=font_prop,fontsize=16)
|
410 |
ax.set_title(title_name , fontproperties=font_prop,fontsize=16)
|
411 |
+
plt.legend(prop=font_properties) # 显示图例
|
412 |
+
fig = plt.gcf()
|
413 |
fig.set_size_inches(18, 12)
|
414 |
|
415 |
return ax
|