fix averaging permolecule and folded trajectories