<0.005) & (abs(df['openPrice']-df['closePrice'].shift(-2))/df['body_length']<0.005),'three_yeah'] = 1df.loc[(df['sort_three_yeah']==1) & (abs(df['closePrice']-df['openPrice'].shift(-3))/df['body_length']<0.005) & (abs(df['openPrice']-df['closePrice'].shift(-3))/df['body_length']<0.005),'four_yeah'] = 1df['three_m_yeah'] = 0df['four_m_yeah'] = 0df.loc[(df['three_yeah']==1) & ((df['body_length']*0.33+df['closePrice'])>df['highestPrice'].shift(-1)),'three_m_yeah'] = 1df.loc[(df['four_yeah']==1) & ((df['body_length']*0.33+df['closePrice'])>df['highestPrice'].shift(-1)) & ((df['body_length']*0.33+df['closePrice'])>df['highestPrice'].shift(-2)),'four_m_yeah'] = 1df['signal'] = 0df['signal_name'] = ''df.loc[df['three_m_yeah']==1,'signal'] = 1df.loc[df['three_m_yeah']==1,'signal_name'] = '三'df.loc[df['four_m_yeah']==1,'signal'] = 2df.loc[df['four_m_yeah']==1,'signal_name'] = '四'file_name = os.path.basename(daily_file_path)title_str = file_name.split('.')[0]line_data = http://www.kingceram.com/post/{'title_str':title_str,'whole_header':['日期','收','开','高','低'],'whole_df':df,'whole_pd_header':['tradeDate','closePrice','openPrice','highestPrice','lowestPrice'],'start_date_str':start_date_str,'end_date_str':end_date_str,'signal_type':'duration','duration_len':[-1,-2],'temp':len(df.loc[(df['signal']==1) | (df['signal']==2)])}return line_data
结果
- 掌财社:什么是低位十字星孕线形态?
- 量化交易9-backtrader回测十字星K线形态图
- 三相电焊机必须接三根火线吗,电焊机可以接三根火线吗
- 眉山市旅游,眉山旅游路线
- 曹操的墓地到底在哪农民在墓碑上发现线索
- 三相四线电表度数计算,三相四线的电表度数的算法
- 万用表怎么查弱电接地,万用表测量线路接地的度数
- 七星漂单钩通线怎么调漂,七星漂怎么调漂图解
- 虎眼万年青怎么养
- 室内绿植怎么养