Add updated analytics code