Data collection and cleanup