title: How to create cumulative tick using Pine Script for TradingView
body: <p>I am trying to create a cumulative histogram based on NYSE Tick for Intra-Day trading. The accumulative indicator should be reset to zero on each day at 9:30am. I have so far created the cumulative histogram but I have no idea how to reset it to zero. Can anyone help? </p>
  
  <pre><code>study(title="NYSE Ticks")
  x = security ("TICK.NY", period, close)
  c = x &gt; x[1] ? green : red
  cti = cum(x)
  plot(cti,style=histogram,color=c,linewidth=4)
  </code></pre>
  
  <p>I am day 1 new to Pine Script. I have also searched similar topic but in vane. Please help. </p>