Extract keys
Extract frequencies