I am new to machine learning. I know Logistic Regression (LR) is a supervised learning technique. Therefore, we need training data to train the model.
I tried to understand the basic steps to get the final RL model. According to my understanding, here are the steps.
We define the LR model, that is, $y = \text{sigmoid}(W x + B)$. Set $W$ and $B$ to zero or another value.
Given the training data (the inputs are $x_1, x_2, \dots, x_m$, and the outputs are $y_1, y_2, \dots, y_m$), we find $W$ and $B$ values by minimizing a cost function using gradient descent.
Then we use the found $W$ and $B$ values. We then again apply a known sample from the training data $\hat{x}$ to get the predicting of $\hat{y}$, that is, $\hat{y} = \text{sigmoid}(W \hat{x} + B)$.
We test the final model on unknown data.
Are these steps correct?
Please, if you could also give me the basic idea behind the supervised technique, I would appreciate it.