changed objective function for the adaptive proposal distribution code