Difference between revisions of "AI:Regression Problems"
Jump to navigation
Jump to search
Line 15: | Line 15: | ||
;J(θ(0),θ(1)) = 0.5m * ∑<sup>m</sup><sub>i</sub>( h( x(i) ) = y(i) )² | ;J(θ(0),θ(1)) = 0.5m * ∑<sup>m</sup><sub>i</sub>( h( x(i) ) = y(i) )² | ||
− | sum_{i=1} | + | <nowiki><math>\sum_{i=1} k²</math></nowiki> |
Revision as of 21:11, 8 April 2019
Learning from a training set.
A training set has m samples of x's (input variables or features) and the resulting y's (output/target variables)
The learning algorithm finds the best matching hypothesis that brings the input to the output values.
The hypothesis can be:
Linear regression with 1 variable (Univariate linear regression)
- h(x) = θ(0) + θ(1)*x
- θ are the hypothesis parameters, it is the weight a feature gets. For the multiplication table θ is just the table you are working on. So for the table of 4, in the above formula θ(1) = 4
The aim of the learning algorithm is to choose θ(0) and θ(1) so that the result for all input values is as close as possible to the given output values.
- J(θ(0),θ(1)) = 0.5m * ∑mi( h( x(i) ) = y(i) )²
<math>\sum_{i=1} k²</math>