So I was studying through some sites and saw a Linear regression problem where a company is attempting to find the correct amount to spend on marketing. The example had a small dataset with units sold and total expenditure historically. The example then shows a function with 3 variables: historic expenditure (list), units sold (list) and the desired number of units they wish to sell. The training data used the historic expense as the independent variable and the units sold as our dependent variable, which was fit with the LinearRegression model. In their example, the answer boiled down to
(desired units sold - model.intercept_)/ model.coef_
so conceptually, I understand the intercept as the constant with the predictor variable @ 0, so it makes sense to subtract the constant value from our value with which we wish to predict on (our desired output of units sold) but I'm having a hard time understanding why we choose to divide that value by the model coefficients? I don't fully understand what the coefficients really mean (weights or something?). Any explanation with math would be helpful.