add option to check error status for a sample set