Update compare_earnings.js

Moved from new_earnings to earnings structure