Quote:
Originally Posted by sandeeps
I get average E_in as ~ 0.13, however the answer is shown as [Answer edited out by admin].
What I have done:  Generated a random line (target function)
 Generated 100 random points; xn
 Computed yn using target function
 Computed w using the linear regression equation
 Computed Ein = mean(h(x) != yn) i.e. number of values incorrectly estimated by w
 Repeated the above steps 1000 times and averaged Ein
What have I done wrong?

The steps seem fine. Can you visually check if the hypothesis line makes sense in a few of the runs?
BTW, if you want to discuss specific answers (chosen or excluded), you need to do so in a thread whose title starts with the warning *ANSWER* per the announcement above.