Added extra checks for samples without parent subject