Added rt mean, variance and dx2
Changed functions to input window length correctly