updated analysis functions