View Single Post
  #2  
Old 09-27-2013, 10:18 PM
yaser's Avatar
yaser yaser is offline
Caltech
 
Join Date: Aug 2009
Location: Pasadena, California, USA
Posts: 1,477
Default Re: How to draw the separating line in 2D input

Quote:
Originally Posted by Ahmed.Elkayesh View Post
This is my first post to the forum and I would like to thank the book authors for the availability online and for choosing to make the book price low.


I have a question and I hope someone will help me answer it

In a 2D input space, we have the components in the W vector, w0 for the bias, and w1, w2 for the 2 dimensions of the input.

If the learning algorithm successfully found the W that could classify all input correctly, how is it possible to draw the separation line(or vector) using the 3 components of the W vector?

How could we map w0,w1,w2 to the Line equation y = ax+ b.


Thanks

Ahmed
The line would be {\bf w}^T {\bf x}=0 which expands as w_0x_0+w_1x_1+w_2x_2=0 with x_0=1 and (x_1,x_2) being the (x,y) coordinates in the conventional y=ax+b formulation. As you can see, you need to diivide out by w_2 to get the coefficient of x_2 which is y to be 1, hence the discrepancy between the 3 parameters in one formulation and the 2 parameters in the other formulation.
__________________
Where everyone thinks alike, no one thinks very much
Reply With Quote