去除macd hist的保留2位小数,例如ADA的hist值太小,四舍五入没有区分度
This commit is contained in:
2
chart.py
2
chart.py
@@ -93,7 +93,7 @@ def add_macd(
|
||||
df["DIF"] = macd
|
||||
df["DEA"] = signal
|
||||
macd_name = f"MACD_{fastperiod}_{slowperiod}_{signalperiod}"
|
||||
df[macd_name] = np.round(hist * 2, 2)
|
||||
df[macd_name] = hist * 2
|
||||
macd_chart = chart.create_subchart(
|
||||
position=position, width=1, height=height, sync=True
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user