netixen

NX_Pivots

600
Just simplified pivots for use with BTCUSD
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 đồ?
//Adapted by netixen from CM_Pivot Points by ChrisMoody 6-14-14 
//Daily, Weekly, Monthly, Yearly Pivots 
//calculations from http://en.wikipedia.org/wiki/Pivot_point 
study(title="Netixen_Pivots", shorttitle="NX_Pivots", overlay=true) 
sd = input(true, title="Show Daily Pivots?")
sw = input(false, title="Show Weekly Pivots?")
sm = input(false, title="Show Monthly Pivots?")
sy = input(false, title="Show Yearly Pivots?")


//Classic Pivot Calculations
pivot = (high + low + close ) / 3.0 
r1 = pivot + (pivot - low)
s1 = pivot - (high - pivot) 
r2 = pivot + (high - low) 
s2 = pivot - (high - low) 

//Daily Pivots 
dtime_pivot = security(tickerid, 'D', pivot[1]) 

offs_daily = 0 
plot(sd and dtime_pivot ? dtime_pivot : na, title="Daily Pivot",style=circles, color=fuchsia,linewidth=2) 

//Weekly Pivots 
wtime_pivot = security(tickerid, 'W', pivot[1]) 

plot(sw and wtime_pivot ? wtime_pivot : na, title="Weekly Pivot",style=circles, color=fuchsia,linewidth=3) 

//Monthly Pivots 
mtime_pivot = security(tickerid, 'M', pivot[1]) 

plot(sm and mtime_pivot ? mtime_pivot : na, title="Monthly Pivot",style=cross, color=fuchsia,linewidth=4) 

//Yearly Pivots
ytime_pivot = security(tickerid, '12M', pivot[1]) 

plot(sy and ytime_pivot ? ytime_pivot : na, title="Yearly Pivot",style=cross, color=fuchsia,linewidth=4)