add analystic code