in GATE
368 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 
 
 

in GATE
368 views

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.
by

Related questions

Quick search syntax
tags tag:apple
author user:martin
title title:apple
content content:apple
exclude -tag:apple
force match +apple
views views:100
score score:10
answers answers:2
is accepted isaccepted:true
is closed isclosed:true

64.3k questions

77.9k answers

244k comments

80.0k users