I have 2 columns and i want diff column as an output.I tried with loops iteration.if i am passing array of values and i want diff column array.
l h diff
100.87 100.87 max(h-l)
99.800778 100.87 max ((h-l),diff[0])
101.1281283 101.1281283 max ((h-l),diff[1])
106.4575807 106.4575807 max ((h-l),diff[2])
109.3212896 109.3212896 .....
107.7907916 109.3212896
105.128359 109.3212896
103.8668187 109.3212896
108.9978396 109.3212896
110.0006197 110.0006197
Can someone help me out.