StockRise for 10 Consecutive Day

From the closing prices of several stocks in this month, find the stocks that are rising for 10 consecutive days.

Solution:

A
1
=file@s("StockRecords.txt").import@t()
2
=A1.derive(UP)
3
=A2.sort(CODE,DT)
4
=A3.group@o(CODE)
5
=A4.run(~.run(UP=if(CL<=CL[-1],1,UP[-1]+1)))
6
=A5.select(~.max(UP)>10).(CODE)

The computation in A6 is shown below: