From 0a3ccd28a05bdaa52081f4e04b5f64d7f415d508 Mon Sep 17 00:00:00 2001 From: Sergey Feldman Date: Mon, 7 Nov 2016 15:29:29 -0800 Subject: [PATCH] Changing predict_std to return_std #2 --- sklearn/linear_model/bayes.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sklearn/linear_model/bayes.py b/sklearn/linear_model/bayes.py index ed232a1f0e76a..453915003a3f5 100644 --- a/sklearn/linear_model/bayes.py +++ b/sklearn/linear_model/bayes.py @@ -228,7 +228,7 @@ def fit(self, X, y): self._set_intercept(X_offset, y_offset, X_scale) return self - def predict(self, X, predict_std=False): + def predict(self, X, return_std=False): """Predict using the linear model. In addition to the mean of the predictive distribution, also its standard deviation can be returned. @@ -242,7 +242,7 @@ def predict(self, X, predict_std=False): X : {array-like, sparse matrix}, shape = (n_samples, n_features) Samples. - predict_std : boolean, optional + return_std : boolean, optional Whether to return the standard deviation of posterior prediction. Returns @@ -254,7 +254,7 @@ def predict(self, X, predict_std=False): Standard deviation of predictive distribution of query points. """ y_mean = self._decision_function(X) - if predict_std is False: + if return_std is False: return y_mean else: if self.normalize: @@ -478,7 +478,7 @@ def fit(self, X, y): self._set_intercept(X_offset, y_offset, X_scale) return self - def predict(self, X, predict_std=False): + def predict(self, X, return_std=False): """Predict using the linear model. In addition to the mean of the predictive distribution, also its standard deviation can be returned. @@ -495,7 +495,7 @@ def predict(self, X, predict_std=False): X : {array-like, sparse matrix}, shape = (n_samples, n_features) Samples. - predict_std : boolean, optional + return_std : boolean, optional Whether to return the standard deviation of posterior prediction. Returns @@ -507,7 +507,7 @@ def predict(self, X, predict_std=False): Standard deviation of predictive distribution of query points. """ y_mean = self._decision_function(X) - if predict_std is False: + if return_std is False: return y_mean else: if self.normalize: