updates to estimation code.