374 views
0 votes
0 votes

Consider the following data. Data describes that a person should/should not buy a house with a given specification. 

Size (feet2 )     No. of Bed-Rooms     Age of Home (Years)     Buy 

2104                                 5                                25                                   No

1416                                 3                                30                                   Yes

1350                                 4                                15                                    Yes

750                                   2                                 05                                    No

 

Use Gradient Descent learning algorithm for logistic regression to predict the price of an unseen house. Values of parameters are given under:  

Ө0   = 0.3  Ө1   = 0.2  Ө2   = 0.4  Ө3   = 0.7  α = 0.2 
 
What to do?

(a) Convert the data into appropriate rages.  

(b) Code the above classification problem in any language.

(c) Run the algorithm for 30 iterations or if it is converged earlier.  

(d) Display the Error Surface 
 
 

1 Answer

0 votes
0 votes
1. Normalize all the data values so that all the entries are in the range 0-1.

2. then you can create the hypothesis function using the given values of Theta and Alpha.

3. Now iterate for each entry and find the Theta which gives the least Cost function.

4. Use that theta to find prices of unknown houses.

 

If you are following the Andrew Ng course then watch the videos for the maths and implementation. Surface plotting isnt necessary but you can do that using matplotlib to visualize your data correctly.

Related questions

1 votes
1 votes
0 answers
4
Venkat Sai asked Mar 29, 2018
809 views
Can anyone tell me their interview experience for machine learning and computing at IIST ?? i heard there are only 3 seats for general category ? what is the procedure fo...