Hi steve.
I want to calculate temperature profile .can I calculate it in input script?
how can I subtract the the average velocity of each bin from each atom velocity in that bin ?

Please keep the list in the loop.
I think you can write a peratom variable that subtracts a binned
ave velocity, e.g. from fix ave/spatial, and then computes the thermal
temp. Or more simply, you could just compute T on the transverse
dimension, e.g. with compute temp/partial. Also compute temp/profile
does the whole operation (temp with streaming vel subtracted out).
Steve