angellance

Simple Session Seperator

179
use utc+3 timezone to match up with MT4
Mã nguồn mở

Với tinh thần TradingView, tác giả của tập lệnh này đã xuất bản nó dưới dạng mã nguồn mở, vì vậy các nhà giao dịch có thể hiểu và xác minh nó. Chúc mừng tác giả! Bạn có thể sử dụng mã này miễn phí, nhưng việc sử dụng lại mã này trong một ấn phẩm chịu sự điều chỉnh của Nội quy nội bộ. Bạn có thể yêu thích nó để sử dụng nó trên biểu đồ.

Thông báo miễn trừ trách nhiệm

Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.

Bạn muốn sử dụng tập lệnh này trên biểu đồ?
study(title="Simple Session Seperator", shorttitle="Simple Session Seperator by Angel Lance", overlay=true)
//use UTC+3 Athens Timezone to match up with metatrader4

timeinrange(res, sess) => time(res, sess) != 0
    
render = input(false,title="Slow but exact background (Refresh page)")
renderRes = render ? "1" : "5"

//Asian
asianSession = "1900-0315" 
asianColor = red
asian = input(true)
bgcolor(asian and timeinrange(renderRes, asianSession) ? asianColor : na, transp=80, title="Asian Session")


//London
londonSession = "0000-0915"
londonColor = blue
london = input(true)
bgcolor(london and timeinrange(renderRes, londonSession) ? londonColor : na, transp=80, title="London Session")


//New York
newyorkSession = "0700-1615" 
newyorkColor = green
newyork = input(true, title="New York")
bgcolor(newyork and timeinrange(renderRes, newyorkSession) ? newyorkColor : na, transp=80, title="New York Session")