Hi @Kalpeshh_Patel
use this code
import pandas_ta as ta
index_chart = tsl.get_historical_data(tradingsymbol='NIFTY NOV FUT', exchange='NFO', timeframe="15")
indi = ta.supertrend(index_chart['high'], index_chart['low'], index_chart['close'], 7, 3)
index_chart = pd.concat([index_chart, indi], axis=1, join='inner')
print(index_chart)
cc = index_chart.iloc[2] # completed_candle
cc_supertrend_color = completed_candle['SUPERTd_7_3.0']
# example entry
if cc_supertrend_color == 1:
print("buy")
if cc_supertrend_color == -1:
print("buy")
# 'Column1 SUPERT_7_3.0 = this will give full supertrend line values' trend
# 'Column2 SUPERTd_7_3.0 = this will show if supertrend is red or green' direction
# 'Column3 SUPERTl_7_3.0 = show values only for green None for red' long
# 'Column4 SUPERTs_7_3.0 = show values only for red None for green' short