# Algorithms from scratch

The general steps are as follows:

1. Get 3 things: The formula for the algorithm, the cost function, the derivatives to be used for gradient descent.&#x20;
2. Initialize the weights and bias.
3. In the fit function set the loop to update the weights in each iteration as per the cost function optimization algorithm.
4. Create a predict function to predict the values.
5. Create a test dataset to test if your function works properly.
6. Plot the results.
