Modified for analytics