added analytics toggling