adding analytics code