Refactor JavaScript to be more object oriented and get the CAPE and interest rate / dividend yeild graphs working