fixed a bug; added min and max to pupildata