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
`!pip install yfinance==0.2.42 --upgrade --no-cache-dir import yfinance as yf
df2 = yf.download(["SPY","QQQ"], "2023-01-01", "2023-12-31", auto_adjust=True,ignore_tz = True) df = yf.download("QQQ", "2023-01-01", "2023-12-31", auto_adjust=True,ignore_tz = True)
def check_datetime_tz(dt): if dt.tzinfo is None: return "Naive" elif dt.tzinfo.utcoffset(dt) is None: return "Naive" else: return "Timezone-aware"
print("\ndf2=",check_datetime_tz(df2.index[0]))
print("df=",check_datetime_tz(df.index[0])) `
The text was updated successfully, but these errors were encountered:
No branches or pull requests
`!pip install yfinance==0.2.42 --upgrade --no-cache-dir
import yfinance as yf
df2 = yf.download(["SPY","QQQ"], "2023-01-01", "2023-12-31", auto_adjust=True,ignore_tz = True)
df = yf.download("QQQ", "2023-01-01", "2023-12-31", auto_adjust=True,ignore_tz = True)
def check_datetime_tz(dt):
if dt.tzinfo is None:
return "Naive"
elif dt.tzinfo.utcoffset(dt) is None:
return "Naive"
else:
return "Timezone-aware"
print("\ndf2=",check_datetime_tz(df2.index[0]))
print("df=",check_datetime_tz(df.index[0]))
`
The text was updated successfully, but these errors were encountered: