New loops implemented, goes back to the beginning ready for data state at the end of the test