gpt4 book ai didi

python - FutureWarning : frame. 附加方法已弃用,请改用 pandas.concat

转载 作者:行者123 更新时间:2023-12-05 04:22:05 25 4
gpt4 key购买 nike

<分区>

这是我的代码:

def gettrigger(self):
dfx = pd.DataFrame()
for i in range(self.lags + 1):
mask = (self.df['%K'].shift(i) < 20 ) & (self.df['%D'].shift(i) < 20)
dfx = dfx.append(mask, ignore_index=True)
return dfx.sum(axis=0)

执行此操作后,我收到此警告:

The frame.append method is deprecated and will be removed from pandas
in a future version. Use pandas.concat instead.
dfx = dfx.append(mask, ignore_index=True)

谁能帮帮我?

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com