We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
kyj880423 님이 알려주신대로 yfinance의 download로 데이터를 받아보시기 바랍니다.
#91 제 PC에서는 backtrader 1.9.76.123 버전에서 정상적으로 동작하는 걸 확인했습니다.
import yfinance as yf #data = bt.feeds.YahooFinanceData(dataname='036570.KS', fromdate=datetime(2017, 1, 1), todate=datetime(2019, 12, 1)) data = bt.feeds.PandasData(dataname=yf.download('036570.KS', '2017-01-01', '2019-12-01', auto_adjust=True))
Originally posted by @INVESTAR in #122 (comment)
다만 buy, sell, Trades - Net Profit/Loss(True) Positive 등등의 기호 출력이 교재와 같지 않은데 이 경우는 어떻게 해결해야할까요?
The text was updated successfully, but these errors were encountered:
# data = bt.feeds.PandasData(dataname=yf.download('036570.KS', '2017-01-01', '2019-12-01', auto_adjust=True)) df = yf.download("036570.KS", start="2024-01-01", end="2024-11-05") df = df.reset_index() # 인덱스를 초기화하여 'Date' 열을 열로 변환 df.columns = ['date', 'adj_close', 'close', 'high', 'low', 'open', 'volume'] # 컬럼 이름 변경 df['date'] = pd.to_datetime(df['date'],format='%Y-%m-%d %H:%M:%S', dayfirst=True) df.set_index('date', inplace=True) data = bt.feeds.PandasData(dataname=df)
Sorry, something went wrong.
No branches or pull requests
#91
제 PC에서는 backtrader 1.9.76.123 버전에서 정상적으로 동작하는 걸 확인했습니다.
Originally posted by @INVESTAR in #122 (comment)
다만 buy, sell, Trades - Net Profit/Loss(True) Positive 등등의 기호 출력이 교재와 같지 않은데 이 경우는 어떻게 해결해야할까요?
The text was updated successfully, but these errors were encountered: