runavg | runningaverage

Calculate the running average of coordinates over specified window size.

runavg [window <window_size>]

Note that for backwards compatibility with ptraj runningaverage is also accepted. Replaces the current frame with a running average over a number of frames specified by window <window_size> (5 if not specified). This means that in order to build up the correct number of frames to calculate the average, the first <window_size> minus one frames will not be processed by subsequent actions. So for example given the input:

runavg window 3
rms first out rmsd.dat

the rms command will not take effect until frame 3 since that is the first time 3 frames are available for averaging (1, 2, and 3). The next frame processed would be an average of frames 2, 3, and 4, etc.