add median and average