Changeset 1433 for branches/0.4stable/yat/regression
 Timestamp:
 Aug 25, 2008, 5:23:42 PM (14 years ago)
 Location:
 branches/0.4stable/yat/regression
 Files:

 2 edited
Legend:
 Unmodified
 Added
 Removed

branches/0.4stable/yat/regression/Local.cc
r1392 r1433 69 69 70 70 size_t nof_fits=data_.size()/step_size; 71 x_ = utility::Vector(nof_fits);72 y_predicted_ = utility::Vector(x_.size());73 y_err_ = utility::Vector(x_.size());71 x_.resize(nof_fits); 72 y_predicted_.resize(x_.size()); 73 y_err_.resize(x_.size()); 74 74 sort(data_.begin(), data_.end()); 75 75 76 // co ying data to 2 utility vectors ONCE to use views from76 // copying data to 2 utility vectors ONCE to use views from 77 77 utility::Vector x(data_.size()); 78 78 utility::Vector y(data_.size()); … … 124 124 assert(i<y_predicted_.size()); 125 125 assert(i<y_err_.size()); 126 x_(i) = x(i*step_size); 126 127 y_predicted_(i) = regressor_>predict(x(i*step_size)); 127 128 y_err_(i) = sqrt(regressor_>standard_error2(x(i*step_size))); 
branches/0.4stable/yat/regression/Local.h
r1392 r1433 70 70 71 71 /// 72 /// @param step_size Size of step between each fit 72 73 /// @param nof_points Number of points used in each fit 73 /// @param step_size Size of step between each fit74 74 /// 75 75 void fit(const size_t step_size, const size_t nof_points);
Note: See TracChangeset
for help on using the changeset viewer.