ChrisMoody

CM_Hourly Pivots

2139 7 421
Simple Code for Hourly Pivot Points Requested by user pippo

Inputs Tab:
Turn On/Off Pivots
Turn On/Off R3/S3
Remove from Favorite Scripts Add to Favorite Scripts
//created by ChrisMoody by request for pippo
//Hourly Pivots
study(title="CM_Hourly_Pivots", shorttitle="CM_Hourly_Pivots", overlay=true) 
sh = input(true, title="Show Hourly Pivots?")
sh3 = input(false, title="Show R3 & S3?")

//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) 
r3 = sh3 and r1 + (high - low) ? r1 + (high - low) : na
s3 = sh3 and s1 - (high - low) ? s1 - (high - low) : na
 
 //Daily Pivots 
htime_pivot = security(tickerid, '60', pivot[1]) 
htime_r1 = security(tickerid, '60', r1[1]) 
htime_s1 = security(tickerid, '60', s1[1]) 
htime_r2 = security(tickerid, '60', r2[1]) 
htime_s2 = security(tickerid, '60', s2[1])
htime_r3 = security(tickerid, '60', r3[1])
htime_s3 = security(tickerid, '60', s3[1])

plot(sh and htime_pivot ? htime_pivot : na, title="Hourly Pivot",style=circles, color=fuchsia,linewidth=3) 
plot(sh and htime_r1 ? htime_r1 : na, title="Hourly R1",style=circles, color=#DC143C,linewidth=3) 
plot(sh and htime_s1 ? htime_s1 : na, title="Hourly S1",style=circles, color=lime,linewidth=3) 
plot(sh and htime_r2 ? htime_r2 : na, title="Hourly R2",style=circles, color=maroon,linewidth=3) 
plot(sh and htime_s2 ? htime_s2 : na, title="Hourly S2",style=circles, color=#228B22,linewidth=3) 
plot(sh and htime_r3 ? htime_r3 : na, title="Hourly R3",style=circles, color=#FA8072,linewidth=3)
plot(sh and htime_s3 ? htime_s3 : na, title="Hourly S3",style=circles, color=#CD5C5C,linewidth=3)
2use
2 years ago
Was it the same for the daily that you publisher recently?
Reply
ChrisMoody PRO 2use
2 years ago
I've published one that does Daily, Weekly, Monthly, Quarterly, Yearly. I tried to add the hourly to that script but the script was too long...So I had to Create a new Version...
Reply
2use ChrisMoody
2 years ago
That one was really awesome
Reply
pippo
2 years ago
Dear Chris, thank you very much indeed for the hourly pivot points. It took you soo little time to make it. Have you a code for Elliott Wave counts, as I choice the points on the chart and it gives the count?
Kindest regards.
Reply
ChrisMoody PRO pippo
2 years ago
It actually took me less than two minutes....I had the formula for Daily and above...I only had to change one word...So it was no problem at all.
Reply
Major New Release for Pivots Indicator

Famous Filtered Pivots Indicator - Many Time Frames Available!!!
Reply
naskove PRO
24 days ago
Chris, how do you keep the chart view from compressing when adding your PP indicator?
Typically use 3 or 5 min.

Thanks
Reply
Ideas Scripts Chart
United States
United Kingdom
India
España
Italia
Brasil
Россия
Türkiye
日本
한국
Home Stock Screener Economic Calendar How It Works Chart Features House Rules Moderators For the WEB Widgets Stock Charting Library Priority Support Feature Request Blog & News FAQ Help & Wiki Twitter
Private Messages Chat Ideas Published Followers Following Priority Support Public Profile Profile Settings Billing Sign Out