Changeset 713 for trunk/yat/regression/Naive.h
- Timestamp:
- Dec 21, 2006, 3:43:31 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/yat/regression/Naive.h
r703 r713 37 37 namespace regression { 38 38 39 /// 40 /// @bief naive fitting. 41 /// 42 /// @todo document 43 /// 39 /** 40 @brief Naive Regression 41 42 Data are modeled as \f$ y_i = \alpha + \epsilon_i \f$ 43 44 */ 44 45 class Naive : public OneDimensional 45 46 { … … 56 57 virtual ~Naive(void); 57 58 59 /** 60 \f$\frac{1}{N-1} \sum (x_i-m)^2 \f$ 61 62 @brief Mean Squared Error 63 */ 64 double chisq(void) const; 65 58 66 /// 59 67 /// This function computes the best-fit for the naive model \f$ y 60 68 /// = m \f$ from vectors \a x and \a y, by minimizing \f$ 61 /// \sum{(y_i-m)^2} \f$. This function is the same as using the 62 /// weighted version with unity weights. 69 /// \sum{(y_i-m)^2} \f$. 63 70 /// 64 71 void fit(const utility::vector& x, const utility::vector& y); 65 72 66 73 /// 67 /// @brief Mean Squared Error 68 /// 69 inline double mse(void) const { return mse_; } 70 71 /// 72 /// Function predicting value using the naive model. 74 /// The predicted value is the average \f$ m \f$ 73 75 /// 74 76 double predict(const double x) const; … … 76 78 /// 77 79 /// @return standard error 80 /// 81 /// @see statistics::Averager 78 82 /// 79 83 double standard_error(const double x) const;
Note: See TracChangeset
for help on using the changeset viewer.