ucsgears

UCS_Fridays

A simple script to show the Fridays (Weekly Option Expiry), of course this is a basic script we can make a few more improvement.

One of many ways to utilize the "dayofweek" variable.

Currently there are no options to draw a vertical line, you can do a background color for the candle.

Future plans - Include monthly option expiry.
從收藏腳本中移除 新增至收藏腳本
// Created by UCSgears
// Simple script to show you Fridays (Weekly Options Expiry)
// Will release a version for Monthly Option Expiry

study("UCS_Fridays", overlay = true)

x = dayofweek == 6 ? 1 : 0

plotshape(x, style = shape.xcross, location = location.top, title="Show Me Fridays")

評論

cool...and I remember there is a script in the library that colors each day too, so perhaps a different color for each Friday through the month. I use the same notification for FX and Fix rates.
+1 回覆
Nice work -- I have to admit I got super excited when I saw the title because I was trying to program a OPEX marker, but was only able to determine every Friday, not every third Friday because despite all the choices there is no ' ' weekokmonth ' variable. Admittedly I didn't spend an inordinate amount of time on it, but now that you;ve jogged my memory maybe I'll try again this afternoon.

Good stuff.
+1 回覆
ucsgears SPYderCrusher
I am starting to work on it as well. Primarily for options.
+1 回覆
Sweet. I outlined a thought process for how one could do it below, curious to see what you come up with or if that was basically your plan as well. Cheers.
回覆
any ideas for plotting expirations for future dates? not just current bar and previous.
回覆
I guess you could do weekofyear, and do like a if <4 then 3, if > 4, then n placeholder +3 something along those lines
回覆
SPYderCrusher SPYderCrusher
greater than and less than symbols didnt show but it should be if less than 4 then n is 3 and if greater than 4 then n placeholder plus 3 (on the assuming 3 would be the third week of the year + friday, then can just add four to that to get February's third friday etc).
+1 回覆
ucsgears SPYderCrusher
I was thinking more basic, dayofmonth and friday. It should work theoretically.
回覆
首頁 股票篩選器 外匯篩選器 加密貨幣篩選器 全球財經日曆 如何運作 圖表功能 價格 推薦朋友 網站規則 幫助中心 網站 & 經紀商解決方案 小工具 圖表解決方案 輕量圖表庫 部落格 & 新聞 推特
概覽 個人資料設定 賬戶和賬單 推薦朋友 我的客服工單 幫助中心 發表的想法 粉絲 正在關注 私人訊息 在線聊天 登出