LFD Book Forum

LFD Book Forum (http://book.caltech.edu/bookforum/index.php)
-   Chapter 1 - The Learning Problem (http://book.caltech.edu/bookforum/forumdisplay.php?f=108)
-   -   Problem 1.12a (http://book.caltech.edu/bookforum/showthread.php?t=4417)

Sandes 09-17-2013 07:03 PM

Problem 1.12a
 
I'm somewhat lost in my attempt to show 1.12 a I can see intuitively that the mean will be the best h value since then Ein is the standard deviation, but I'm not sure where to go from there. I've already finished B and C, A is the only part I'm having trouble with.

Perhaps I'm going in the wrong direction but one of the things I realized is that the constraint could be restated as minimizing h^2 -2 h yn summed over all N but that could be going off in completely the wrong direction.

Adding some value a to the mean produces (mean-yn)^2 + a^2 +2 a(mean-yn) That's another possible approach but I'm not really sure where I would take that approach either.

Sweater Monkey 09-17-2013 10:09 PM

Re: Problem 1.12a
 
Quote:

Originally Posted by Sandes (Post 11489)
Perhaps I'm going in the wrong direction but one of the things I realized is that the constraint could be restated as minimizing h^2 -2 h yn summed over all N but that could be going off in completely the wrong direction.

This is what I did and it led to the correct answer of hmean

To start off work on factoring out h, then it should become more obvious how to manipulate the function to find its minimum value. Good luck!

meixingdg 09-18-2013 08:35 PM

Re: Problem 1.12a
 
I tried to take the derivative of the function to find the minimum, but I'm still not sure how the minimum corresponds to h being the in-sample mean.
Also, what exactly is hmean? It seems to be a scalar value, a number of some sort, but I thought that h is a hypothesis/function?

magdon 09-19-2013 04:55 AM

Re: Problem 1.12a
 
Quote:

Originally Posted by Sandes (Post 11489)
I
Perhaps I'm going in the wrong direction but one of the things I realized is that the constraint could be restated as minimizing h^2 -2 h yn summed over all N but that could be going off in completely the wrong direction.

This is the right idea. Your hypothesis h is just a number in this case. Ein is a function of this number (variable) h. One way to minimize a function of a variable h is to take the derivative and set it to zero.


All times are GMT -7. The time now is 03:39 PM.

Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
The contents of this forum are to be used ONLY by readers of the Learning From Data book by Yaser S. Abu-Mostafa, Malik Magdon-Ismail, and Hsuan-Tien Lin, and participants in the Learning From Data MOOC by Yaser S. Abu-Mostafa. No part of these contents is to be communicated or made accessible to ANY other person or entity.