Task: In the above task, I am using number of letters in my name as a, and number of letters of my surname as b. So: Asadbek – letters Axrorov – letters Function: y = 7x + Initial data for training
In the above task, I am using number of letters in my name as a, and number of letters of my surname as b. So: Asadbek – 7 letters Axrorov – 7 letters Function: y = 7x + 7
Initial data for training:
X y
1 14
2 21
3 28
4 …….
Calculations:
We wrote down formula related things. Now it’s time to write an actual code:
As you can see, value is 35.84044. Almost the same with actual value: y = 7x + 7 = 28 + 7 = 35
Graph:
Link to google sheet: https://docs.google.com/spreadsheets/d/145knvn2ZEWh2cXM5lyfWTfitho1cwhIqr9oJHTFPYEQ/edit?usp=sharing
Our values are so near to the actual values. So f(x) function graph overlapping y function graph. Both graphs are drawn there.
Conclusion While doing work 1, I learned how linear regression works. And now I can apply this knowledge to another problem sets as well.