Library "TimeFunctions"
Utility functions to handle time in Pine Script
TimeframetoInt()
Returns an int that corresponds to a timeframe string:
"1" => 1
"5" => 5
"10" => 10
"15" => 15
"30" => 30
"60" => 60
"H1" => 60
"H4" => 240
"1D" => 1440
BarsSinceOpen()
Returns the number of bars that have passed since the opening of the New York Session.