Serial correlation test in r