returned->results and StatHat call outside of loop