raise error for unkown samples and added test for measurement deletion