MLPACK  1.0.4
linear_regression.hpp
Go to the documentation of this file.
00001 
00022 #ifndef __MLPACK_METHODS_LINEAR_REGRESSION_LINEAR_REGRESSION_HPP
00023 #define __MLPACK_METHODS_LINEAR_REGRESSION_LINEAR_REGRESSION_HPP
00024 
00025 #include <mlpack/core.hpp>
00026 
00027 namespace mlpack {
00028 namespace regression  {
00029 
00033 class LinearRegression
00034 {
00035  public:
00042   LinearRegression(arma::mat& predictors, const arma::vec& responses);
00043 
00049   LinearRegression(const std::string& filename);
00050 
00056   LinearRegression(const LinearRegression& linearRegression);
00057 
00061   LinearRegression() {}
00062 
00063 
00067   ~LinearRegression();
00068 
00075   void Predict(const arma::mat& points, arma::vec& predictions);
00076 
00078   const arma::vec& Parameters() const { return parameters; }
00080   arma::vec& Parameters() { return parameters; }
00081 
00082  private:
00087   arma::vec parameters;
00088 };
00089 
00090 }; // namespace linear_regression
00091 }; // namespace mlpack
00092 
00093 #endif // __MLPACK_METHODS_LINEAR_REGRESSCLIN_HPP