How to compare the current series of data with previous series using kapacitor (tick script)

OK, Thanks for your kindly help. :slight_smile: