changed changerate to take Date into account