update analytics code for rollup purposes