Skip to content

Commit

Permalink
Changing predict_std to return_std scikit-learn#2
Browse files Browse the repository at this point in the history
  • Loading branch information
sergeyf committed Nov 7, 2016
1 parent b905a23 commit 0a3ccd2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions sklearn/linear_model/bayes.py
Expand Up @@ -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.
Expand All @@ -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
Expand All @@ -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:
Expand Down Expand Up @@ -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.
Expand All @@ -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
Expand All @@ -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:
Expand Down

0 comments on commit 0a3ccd2

Please sign in to comment.