The following link gives an implementation of the gradient descent algorithm in C.
Gradient Descent for optimization of linear regression.
Data set used in the code.(Binary file,not in human readable form)
Dataset:
size | cost |
+------+------+
| 1700 | 50 |
| 1000 | 32 |
| 1280 | 30 |
| 1324 | 34 |
| 1324 | 33 |
| 1550 | 56 |
| 3500 | 250 |
| 982 | 35 |
| 2500 | 95 |
| 2600 | 85 |
| 3108 | 100 |
| 4000 | 200 |
| 1500 | 24 |
| 1900 | 42 |
| 1713 | 45 |
| 2000 | 45 |
| 2200 | 55 |
-------------------
The algorithm is as per the Stanford University Machine Learning course, but it fails to fetch proper outputs because the parameters become infinity (nan) on execution.(both in c and python).
Is the problem with the implementation of algorithm or choice of language or the dataset?
--
Regards,
Rajeev SB Tech CSE Student
Government Engineering College,Thrissur