[mlpack] 17/149: Spacing and line length fixes.
Barak A. Pearlmutter
barak+git at pearlmutter.net
Sat May 2 09:11:04 UTC 2015
This is an automated email from the git hooks/post-receive script.
bap pushed a commit to branch svn-trunk
in repository mlpack.
commit d96c2027ed33176da4dabd9e0bbfc8cfb487524a
Author: rcurtin <rcurtin at 9d5b8971-822b-0410-80eb-d18c1038ef23>
Date: Sat Sep 27 16:35:43 2014 +0000
Spacing and line length fixes.
git-svn-id: http://svn.cc.gatech.edu/fastlab/mlpack/trunk@17195 9d5b8971-822b-0410-80eb-d18c1038ef23
---
src/mlpack/methods/linear_regression/linear_regression.cpp | 11 +++++++----
1 file changed, 7 insertions(+), 4 deletions(-)
diff --git a/src/mlpack/methods/linear_regression/linear_regression.cpp b/src/mlpack/methods/linear_regression/linear_regression.cpp
index 753ea08..17dafae 100644
--- a/src/mlpack/methods/linear_regression/linear_regression.cpp
+++ b/src/mlpack/methods/linear_regression/linear_regression.cpp
@@ -96,10 +96,13 @@ void LinearRegression::Predict(const arma::mat& points, arma::vec& predictions)
{
if (intercept)
{
- // We want to be sure we have the correct number of dimensions in the dataset.
- Log::Assert(points.n_rows == parameters.n_rows-1);
- // Get the predictions, but this ignores the intercept value (parameters[0]).
- predictions = arma::trans(arma::trans(parameters.subvec(1, parameters.n_elem - 1)) * points);
+ // We want to be sure we have the correct number of dimensions in the
+ // dataset.
+ Log::Assert(points.n_rows == parameters.n_rows - 1);
+ // Get the predictions, but this ignores the intercept value
+ // (parameters[0]).
+ predictions = arma::trans(arma::trans(parameters.subvec(1,
+ parameters.n_elem - 1)) * points);
// Now add the intercept.
predictions += parameters(0);
}
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/mlpack.git
More information about the debian-science-commits
mailing list