Skip to content

Commit

Permalink
Changes name of function
Browse files Browse the repository at this point in the history
  • Loading branch information
quant@alpacka committed Jan 18, 2023
1 parent 71db76e commit b541f25
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions strength.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ def create_report(ticker, name, asset_stats):
asset_stats.above_ma200,
asset_stats.ma50_gt_ma200)

def get_ticker(ticker):
ticker = yf.Ticker(ticker)
def get_history(symbol):
ticker = yf.Ticker(symbol)
df = ticker.history("1y")
return df

Expand All @@ -74,7 +74,7 @@ def get_ma_period(ma_period_str):

stats_tickers = []
for ticker in list:
df = get_ticker(ticker)
df = get_history(ticker)
stats = calc_stats(df, get_ma_period(args.ma_period))
stats_tickers.append(AssetData(ticker, list[ticker]["name"], stats))

Expand Down

0 comments on commit b541f25

Please sign in to comment.