TradingView
kashinme
6 Th12 2019 21:01

Renko on Candlesticks 

Brent Crude Oil Futures (Jan 2020)MOEX

Mô tả

This script drowse renkoboxes on top of candlesticks. This script does not repaint and can be used for alerts generation. If you add Renko to the same chart using security function it won't be the same (which seems to be a bug in TV). To check if my implementation is correct you can open Renko in a separate window and check timestamps.
Unlike standard implementation, when you use ATR based Renko bars, every box can have different size! The current ATR is applied after every bar. The standard implementation takes the current ATR value and applies it to the whole chart, so the chart may look totally different when you reload the page.

Phát hành các Ghi chú

This update introduces multiplier for every Renko box. Since candlesticks is a timebased chart and Renko is not, it is possible that one candlestick generates more than one box. If you build a Renko based strategy, you definitely want to know when there''s just a new box and when there's a movement across multiple boxes

Phát hành các Ghi chú

bug fix: Renko box created by rapid movement was multiplier times size which is not correct.

Phát hành các Ghi chú

Another milestone achieved, the script can now optionally calculate Renko MA (for the time being it's a simple moving average of box waists). Other MA options (both types and sources) are yet to come. The first task right now is to make it volume weighted. And yes, I trade crude oil on FORTS, so it should be possible to get volume data from other tickers as well!
Bình luận
JoseMetal
Any chance on getting the source? :)
kosorof
Hi Igor, Is it possible to show the code for this indicator?
kashinme
I realised that the MA is slightly different in compare with what would have been drawn on the standard TV Renko chart. The difference is that when a strong price action occurs within the chart timeframe that covers multiple boxes, the standard chart would draw all these boxes and consider all of them during calculation. I can implement the same behaviour using the multiplier value introduced on Dec 6 but I need sometime now to consider if it is better. The main culprit now is that for volume weighted line it won't be possible to apply an adequate weight to such rapid movements.
kashinme
The next step is to calculate the moving average (and vwma is of a special interest since Renko ignores volumes). Either I'm yet bad at pine script or there's no simple solution since the rvwma (Renko volume weighed moving average) must not be updated on every candle but only when a new box appears. Stay tuned!
Thêm nữa