Inverse scaling of coefficient using SkLearn I had constructed a simple Multiple linear regression model, where I have 2 independent variables and a target (dependent variable).
Now, I transformed my independent variable using StandardScaler.fit_transform() and ran my model. The problem is the coefficient that I am getting is for the scaled dataset now. They are insanely large for my use.
Is there any way that I can get a coefficient from the model that will work with my non-scaled data?
PS: What I am looking for is software implementation so that I can get intercept and 2 coefficients all of which will be used later in the program. Right now my coefficient will only work if my input data (test data) is also standardized.

Before using the model, you should also scale your test data with the same coefficients that you found using the training set.
Alternatively, you can also rewrite your regression equation as follows by hand:
$$\begin{align}y&=\alpha x_1'+\beta x_2'+\theta=\alpha\frac{x_1-\mu}{\sigma_1}+\beta\frac{x_2-\mu_2}{\sigma_2}+\theta\\&=\frac{\alpha}{\sigma_1}x_1+\frac{\beta}{\sigma_2}x_2+\left(\theta-\frac{\alpha\mu_1}{\sigma_1}-\frac{\beta\mu_2}{\sigma_2}\right)\end{align}$$
Where $x_1',x_2'$ are standardized independent variables, and $\alpha, \beta, \theta$ are the coefficients of the standardized model. I'd definitely prefer the first approach as it is equivalent and you'll stay in the library implementation.
