
* 겪고 있는 문제 상황을 최대한 자세하게 작성해주세요.
* 문제 해결을 위해 어떤 시도를 해보았는지 구체적으로 함께 알려주세요.
안녕하세요?강의를 재미있게 들은 수강생입니다. 그런데 1강때도 그렇고 2강때도 그렇고 어떤건 오류가 나서 진도를 같이 따라가지 못했습니다
1.
pip install finance-datareader
import pandas as pd
import FinanceDataReader as fdr
# 삼성전자(005930.KS)의 2022년 주가 정보를 가져옵니다.
start_date = '2022-01-01'
end_date = '2022-12-31'
df = fdr.DataReader('005930', start_date, end_date)
# 가져온 주가 정보를 출력합니다.
print(df)
-------
오류
File "<ipython-input-6-99425166e8b9>", line 1
pip install finance-datareader
^
SyntaxError: invalid syntax
2.
코스피지수
import FinanceDataReader as fdr
# 코스피(KOSPI) 지수를 가져옵니다.
index = 'KOSPI' # 지수 심볼 (코스피: 'KOSPI')
# FinanceDataReader를 사용하여 지수 데이터를 가져옵니다.
df = fdr.DataReader(index, start='2022-01-01', end='2022-12-31')
# 가져온 지수 데이터를 출력합니다.
print(df)
--------------
오류
HTTP Error 404: Not Found - symbol "KOSPI"not found or invalid periods
Empty DataFrame
Columns: []
Index: []
3.
캔들차트
!pip install mplfinace
-----
오류
Looking in indexes: https://pypi.org/simple, https://us-python.pkg.dev/colab-wheels/public/simple/
ERROR: Could not find a version that satisfies the requirement mplfinace (from versions: none)
ERROR: No matching distribution found for mplfinace
