LFD Book Forum  

Go Back   LFD Book Forum > Book Feedback - Learning From Data > Chapter 3 - The Linear Model

Thread Tools Display Modes
Old 07-12-2017, 05:41 PM
tikenn tikenn is offline
Junior Member
Join Date: Jun 2017
Posts: 3
Default Problem 3.6(a)

I think this is similar to the answer provided for problem 3.5, but I am having a difficult time understanding why, in Problem 3.4, the error is continuous and differentiable at the point y_n\textbf{w}^T\textbf{x}_n=1. I have the three cases looking like this so far:

y_n\textbf{w}^T\textbf{x}_n>1 in which I believe E(\mathbf{x}_n) = 0
y_n\textbf{w}^T\textbf{x}_n<1 in which I believe E(\mathbf{x}_n) = (1 - y_n\textbf{w}^T\textbf{x}_n)^2
y_n\textbf{w}^T\textbf{x}_n=1 in which I believe E(\mathbf{x}_n) = 0

These cases would make y_n\textbf{w}^T\textbf{x}_n=1 non-differentiable because the derivatives from the left and right are different. Am I evaluating the error from the book wrong --> e_n(\textbf{w})=(\max(0,1-y_n\textbf{w}^T\textbf{x}_n))^2?
Reply With Quote
Old 07-15-2017, 02:27 PM
htlin's Avatar
htlin htlin is offline
Join Date: Aug 2009
Location: Taipei, Taiwan
Posts: 567
Default Re: Problem 3.6(a)

Are the derivatives on the two sides really different? :-)
When one teaches, two learn.
Reply With Quote
Old 07-16-2017, 12:36 AM
tikenn tikenn is offline
Junior Member
Join Date: Jun 2017
Posts: 3
Default Re: Problem 3.6(a)

I apologize, I realize I made an error in labeling the problem that my question refers to. My original question actually refers to Problem 3.4a.

Originally Posted by htlin View Post
Are the derivatives on the two sides really different? :-)
Anyway, thank you for the hint! My confusion was with how problem 3.5 and problem 3.4 were so different, but I forgot to evaluate the gradients all the way through for both. Thanks!
Reply With Quote
Old 08-24-2017, 05:05 AM
subbupd subbupd is offline
Join Date: Aug 2017
Location: Singapore
Posts: 14
Default Re: Problem 3.6(a)

Correct - evaluating the gradients would work!
Reply With Quote


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT -7. The time now is 05:41 AM.

Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2018, 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.