-2
내 범례가 오른쪽 상단에 표시되지만 AAPL과 IBM은 하나의 문자로 표시됩니다. 위장 할 수 없습니다.도표에서 범례가 올바르게 표시되도록
import quandl
import pandas as pd
import matplotlib.pyplot as plt
def get_mean_volume(symbol):
df = quandl.get("YAHOO/"+str(symbol))[::-1]
return df[['High', 'Adjusted Close']]
stock = ['AAPL', 'IBM']
for s in stock:
plt.plot(get_mean_volume(s))
plt.legend(s)
plt.ylabel('Price')
plt.xlabel('Date')