Is your feature request related to a problem? Please describe.
Often I need to apply indicators on other columns then the usual. Since all columns a re hard coded I simply can not which is a pity. Here is an example
def AVGPRICE(df):
"""
Average Price
"""
avgprice_list = []
i = 0
while i < len(df['Close']):
avgprice = (df['Open'][i] + df['High'][i] + df['Low'][i] + df['Close'][i]) / 4
avgprice_list.append(avgprice)
i += 1
return avgprice_list
Describe the solution you'd like
Simply adding the column names as parameters with defaults would not change the current behavior but I would have the ability to use different columns:
Is your feature request related to a problem? Please describe. Often I need to apply indicators on other columns then the usual. Since all columns a re hard coded I simply can not which is a pity. Here is an example
Describe the solution you'd like Simply adding the column names as parameters with defaults would not change the current behavior but I would have the ability to use different columns:
def AVGPRICE(df, open='open', high='high', low='low', close='close'):
Describe alternatives you've considered Currently I am forced to use plain talib functions which depend on the C library but I would prefer yours.