如何在5个小节内找到哪个最高的高绿色条,不包括当前条?
我想找到最后5个棒的最高高杠,而不是当前的棒(当前的棒可能是最高的绿色条,所以我需要排除它),
我尝试过,但似乎不正确
find = high == highest(high, 5) and close > open and bar_index > 0 and bar_index < 6
numb = barssince(find)
high_of_that_bar = high[numb]
low_of_that_bar = low[numb])
谢谢你帮助我
I would like to find the green bar which is the highest high bar of last 5 bars, and not the current bar (the current bar may be the highest green one, so I need to exclude it)
I tried this but it seems not correct
find = high == highest(high, 5) and close > open and bar_index > 0 and bar_index < 6
numb = barssince(find)
high_of_that_bar = high[numb]
low_of_that_bar = low[numb])
Thank you for helping me
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这应该做你想要的。
这显示了我有第二个意见的盘中时间范围的分数条形指数
,而且看来
bar_index
毕竟不是分数。str.format()
只用逗号将数千个分开。这很清楚:
This should do what you want.
This shows the fractional bar-index for intraday timeframes
I got a second opinion, and it seems
bar_index
is not fractional after all.str.format()
just separates thousands with commas.This makes it clear: