scikit-learn/scikit-learn — pull request #770 by amueller (2012-04-13 14:39:05+00:00)
Title: MRG grid_search forgets estimators

This should address #565 in the least intrusive way.

It is still possible to set ``refit=False``, but then it is not possible to use ``predict`` or ``best_estimator_`.
Now ``best_estimator_`` is a property that returns the best estimator when ``fit`` was called with ``refit=True`` and raises an appropriate error if not.
This should keep the API as consistent as possible. It only breaks if someone used the best estimator without refitting - which I don't feel is a very good idea any way.

My reasoning was that maybe someone has a big dataset and uses GridSearch with ShuffleSplit and a low train_size. Then they might not want to fit to the whole dataset.
This option is now available without really changing anything for the average user.

Still need to document the changes in whatsnew.