INVITE-ONLY SCRIPT
已更新 The Real Koops - Darvas Box v2.1

What Is the Darvas Box?
The Darvas Box strategy was developed by Nicholas Darvas. Aside from being a well known dancer, he began trading stock in the 1950s. Based on his success in trading, he was approached to write a book on his strategy. The book, “How I Made $2,000,000 in the Stock Market,” outlines his approach together with “You can still make it in the market”.
Darvas Box Implementation
The intend behind the Darvas box was for it to be used for rapidly rising technology stocks, and in fact it was never tested or used by Darvas for Commodities. This implementation of the Darvas Box was created specifically in support of Commodity Trends, which tend to be very volatile over long periods of time. The main ones for an uptrend (e.g. longing the market. Shorting the market would work exactly the opposite):
1. When the price of a rapidly rising stock (pls note rapidly rising is key - we are not interested in a sideways trend) is reaching a resistance point, which is does not surpass for three or more consecutive days, that point represents the top of the box.
2. If, after falling from the upper limit, the stock reaches a downward resistance point which it does not penetrate for three of more consecutive days, that level represents the bottom of the box.
3. A stock is in a rising trend when it is in the topmost box. If it remains there, its price fluctuations should be ignored, and the stock is a HOLD.
4. If the price of the stock moves above the top of this topmost box, this stock becomes a BUY. A 10% stop loss should be set at the breakout.
5. Having formed a new higher box, if the price falls below the bottom into the stop loss area of this box, the stock is a SELL.
6. There is no reason to HOLD or BUY a stock that is not in its topmost box.
7. In case a candle pierces out of the top of the box while establishing the bottom of the box, the box is invalidated.
8. If the Box is broken out of on the top, the color is Yellow. If the Box is broken out of on the bottom, the color is Blue.
9. If a Box is being formed in the current timeframe, it is colored Grey, and has clear Buy and Stop Loss indicators so that the user knows how to configure his/her Broker.
10. All parameters for the implementation have been made configurable, so that users can tweak both the presentation of the boxes (background color, border width and style) as well as the configuration of the breakout %, stop loss %, textual presentation and box validation e.g. display arrows where the top and the bottom of the box was drawn, draw boxes only from All Time High back test after a configurable number of years, the number of boxes to be drawn from the last box etc.
11. In addition, two other key principles are critical for application of the indicator:
1. The stock’s price must be at or above its ATH for the past 3 years or more.
2. The volume profile needs to indicate a rapidly growing volume or insider buying (e.g., a volume spike).
How is this implementation different from others?
This implementation holds fully true to the way Darvas described his Darvas Box in his books, but applies it to Commodities. It is in addition, highly configurable, so that it can be used to debug itself (at which points have box boundaries been drawn), and it provides Buy/Sell/Stop Loss levels for entries and exits – again, highly configurable, with defaults set as per Darvas’ books.
Finally, it works over daily to quarterly timeframes (it is not suitable for high frequency trading).
How to use this Indicator?
First, use it with the default settings. Once a grey box is drawn for the current timeframe for the commodity you are interested in investing in (based on Darvas principles outlined above), this box will indicate a Buy level and a Stop loss level based on the principles described above, allowing you to make a purchase decision for that commodity asset accordingly. Then, stay the trade. As the stock continues to move up, more Darvas Boxes will be drawn with new Buy levels and stop loss levels – either add to your position or keep the original investment in play. Once a trend reversal occurs, the Stop loss level will be used to get you out of the trade.
Second, once you are comfortable with this trading methodology, you can refine the script to use a color scheme as you prefer for your Tradingview, as well as set buy, stop loss and sell levels, aligned with your own level of comfort to deal with volatility.
If you wonder why a certain box was drawn at certain levels, you can use the green and red arrows to show the levels based upon which the boxes were drawn.
The Darvas Box strategy was developed by Nicholas Darvas. Aside from being a well known dancer, he began trading stock in the 1950s. Based on his success in trading, he was approached to write a book on his strategy. The book, “How I Made $2,000,000 in the Stock Market,” outlines his approach together with “You can still make it in the market”.
Darvas Box Implementation
The intend behind the Darvas box was for it to be used for rapidly rising technology stocks, and in fact it was never tested or used by Darvas for Commodities. This implementation of the Darvas Box was created specifically in support of Commodity Trends, which tend to be very volatile over long periods of time. The main ones for an uptrend (e.g. longing the market. Shorting the market would work exactly the opposite):
1. When the price of a rapidly rising stock (pls note rapidly rising is key - we are not interested in a sideways trend) is reaching a resistance point, which is does not surpass for three or more consecutive days, that point represents the top of the box.
2. If, after falling from the upper limit, the stock reaches a downward resistance point which it does not penetrate for three of more consecutive days, that level represents the bottom of the box.
3. A stock is in a rising trend when it is in the topmost box. If it remains there, its price fluctuations should be ignored, and the stock is a HOLD.
4. If the price of the stock moves above the top of this topmost box, this stock becomes a BUY. A 10% stop loss should be set at the breakout.
5. Having formed a new higher box, if the price falls below the bottom into the stop loss area of this box, the stock is a SELL.
6. There is no reason to HOLD or BUY a stock that is not in its topmost box.
7. In case a candle pierces out of the top of the box while establishing the bottom of the box, the box is invalidated.
8. If the Box is broken out of on the top, the color is Yellow. If the Box is broken out of on the bottom, the color is Blue.
9. If a Box is being formed in the current timeframe, it is colored Grey, and has clear Buy and Stop Loss indicators so that the user knows how to configure his/her Broker.
10. All parameters for the implementation have been made configurable, so that users can tweak both the presentation of the boxes (background color, border width and style) as well as the configuration of the breakout %, stop loss %, textual presentation and box validation e.g. display arrows where the top and the bottom of the box was drawn, draw boxes only from All Time High back test after a configurable number of years, the number of boxes to be drawn from the last box etc.
11. In addition, two other key principles are critical for application of the indicator:
1. The stock’s price must be at or above its ATH for the past 3 years or more.
2. The volume profile needs to indicate a rapidly growing volume or insider buying (e.g., a volume spike).
How is this implementation different from others?
This implementation holds fully true to the way Darvas described his Darvas Box in his books, but applies it to Commodities. It is in addition, highly configurable, so that it can be used to debug itself (at which points have box boundaries been drawn), and it provides Buy/Sell/Stop Loss levels for entries and exits – again, highly configurable, with defaults set as per Darvas’ books.
Finally, it works over daily to quarterly timeframes (it is not suitable for high frequency trading).
How to use this Indicator?
First, use it with the default settings. Once a grey box is drawn for the current timeframe for the commodity you are interested in investing in (based on Darvas principles outlined above), this box will indicate a Buy level and a Stop loss level based on the principles described above, allowing you to make a purchase decision for that commodity asset accordingly. Then, stay the trade. As the stock continues to move up, more Darvas Boxes will be drawn with new Buy levels and stop loss levels – either add to your position or keep the original investment in play. Once a trend reversal occurs, the Stop loss level will be used to get you out of the trade.
Second, once you are comfortable with this trading methodology, you can refine the script to use a color scheme as you prefer for your Tradingview, as well as set buy, stop loss and sell levels, aligned with your own level of comfort to deal with volatility.
If you wonder why a certain box was drawn at certain levels, you can use the green and red arrows to show the levels based upon which the boxes were drawn.
發行說明
Updated to reflect the proper release (2.1 versus 2.0).發行說明
Script updated to version 2.2 due to a bug where the Green Break Out Box was not drawn to the last candle.僅限邀請腳本
只有經作者授權的使用者才能訪問此腳本,且通常需付費。您可以將此腳本加入收藏,但需先向作者申請並獲得許可後才能使用 — 點擊此處了解更多。如需更多詳情,請依照作者說明或直接聯繫TheRealKoops。
除非您完全信任其作者並了解腳本的工作原理,否則TradingView不建議您付費或使用腳本。您也可以在我們的社群腳本中找到免費的開源替代方案。
作者的說明
Thank you for your interest in my script. Access can be gained via my website - link is in my bio. Kind regards, The Real Koops
提醒:在請求訪問權限之前,請閱讀僅限邀請腳本指南。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。
僅限邀請腳本
只有經作者授權的使用者才能訪問此腳本,且通常需付費。您可以將此腳本加入收藏,但需先向作者申請並獲得許可後才能使用 — 點擊此處了解更多。如需更多詳情,請依照作者說明或直接聯繫TheRealKoops。
除非您完全信任其作者並了解腳本的工作原理,否則TradingView不建議您付費或使用腳本。您也可以在我們的社群腳本中找到免費的開源替代方案。
作者的說明
Thank you for your interest in my script. Access can be gained via my website - link is in my bio. Kind regards, The Real Koops
提醒:在請求訪問權限之前,請閱讀僅限邀請腳本指南。
免責聲明
這些資訊和出版物並不意味著也不構成TradingView提供或認可的金融、投資、交易或其他類型的意見或建議。請在使用條款閱讀更多資訊。