OPEN-SOURCE SCRIPT

Last Friday of Month

업데이트됨
This script marks the last Friday of the month in a daily chart because this is the day when BTC and ETH options expire according to Deribit.
I only found a script that highlights the 3rd Friday of the month, which is not what I wanted.
This script tries to figure out the correct number of days per month but is not aware of holidays which might displace the expiry date.
릴리즈 노트
[Updated using a clean chart.]

This script tries to mark the last Friday of the month in the chart with a vertical line and/or a label.
It is meant for use on a daily BTC chart.

Price may tend toward a level known as the "max pain point" when options expire. See these articles:
coindesk.com/bitcoin-options-market-eyes-4-2b-expiry-on-friday
insights.deribit.com/education/maximum-pain-for-option-buyers-going-into-expiration/

Deribit is a place where you can trade BTC and ETH options. Monthly and quarterly options expiry
dates are relevant. From deribit.com/pages/information/Introduction_Policy:
Daily options expire every day at 08:00 UTC.
Weekly options expire on each Friday of each week at 08.00 UTC.
Monthly options expire on the last Friday of each calendar month at 08.00 UTC.
Quarterly options expire on the last Friday of each calendar quarter at 08.00 UTC.
릴리즈 노트
UPDATE: Now also shows the expiration Friday for the current month even if it lies in the future.
릴리즈 노트
Added the URL where you can look up the max pain point in the comment.
(It is metrics.deribit.com/options?index=BTC)
릴리즈 노트
  • Fixed the logic for finding Fridays.
  • No output if timeframe is different from 1 day.
  • Extended the description in the header of the source code.

Apologies, dudes and dudesses. The previous version was pretty broken.
How hard can it be to find the Fridays? Well, pretty hard for me, it seems... :-)
릴리즈 노트
Another bug fix for the future last Friday of the month (how embarrasing).
Added highlighting of past quadruple witching Fridays (future dates not working, yet).
Converted to Pine Script v5.
릴리즈 노트
This is a complete rewrite that should solve all update problems.
Quadruple witching Fridays are now fully supported for the past and the future.
See also the updated documentation at the top of the script code.

Looking forward: I think it would be nice to receive an alert from this script some days before an upcoming special Friday. Let me know if you would find this useful.
릴리즈 노트
Fix that makes the script work correctly with symbols that use a different time base (e.g. NIKKEI and NFTY).
Commitment of Traders (COT)expiryoptions

오픈 소스 스크립트

진정한 TradingView 정신에 따라, 이 스크립트의 저자는 트레이더들이 이해하고 검증할 수 있도록 오픈 소스로 공개했습니다. 저자에게 박수를 보냅니다! 이 코드는 무료로 사용할 수 있지만, 출판물에서 이 코드를 재사용하는 것은 하우스 룰에 의해 관리됩니다. 님은 즐겨찾기로 이 스크립트를 차트에서 쓸 수 있습니다.

차트에 이 스크립트를 사용하시겠습니까?

면책사항