Changeset 731 for trunk/yat/regression/MultiDimensional.cc
 Timestamp:
 Jan 6, 2007, 5:06:19 PM (16 years ago)
 File:

 1 edited
Legend:
 Unmodified
 Added
 Removed

trunk/yat/regression/MultiDimensional.cc
r727 r731 26 26 #include "yat/utility/vector.h" 27 27 28 #include <cassert> 29 28 30 namespace theplu { 29 31 namespace yat { … … 52 54 void MultiDimensional::fit(const utility::matrix& x, const utility::vector& y) 53 55 { 56 assert(x.rows()==y.size()); 54 57 covariance_=utility::matrix(x.columns(),x.columns()); 55 58 fit_parameters_=utility::vector(x.columns()); … … 76 79 double MultiDimensional::predict(const utility::vector& x) const 77 80 { 81 assert(x.size()==fit_parameters_.size()); 78 82 return fit_parameters_ * x; 79 83 }
Note: See TracChangeset
for help on using the changeset viewer.