it is not clear to me how the get_delta () function works, but if you have to apply the same function to a group of columns you can do something like this.
df=DataFrame(rand(1:1000, 10^6, 300),:auto)
g=groupby(df, :x1)
Diff(x) = -(-(extrema(x)...))
combine(g, 3:300 .=> Diff)