Category "linear-regression"

To which value in the statsmodels summary relates the error bar size in the plot?

With the following code, I get a plot how the regression was done for my data. In the plot also vertical (error?) bars are shown. To which number in the sum

How to obtain RMSE out of lm result?

I know there is a small difference between $sigma and the concept of root mean squared error. So, i am wondering what is the easiest way to obtain RMSE out of l

How to make predictions even with NAs using predict()?

I want to use predict() with a polr() model to predict variable z, as per the following code. This first is the df to train the model and the subsequent test da

recursively split a dataframe with partykit::lmtree as a stump tree

I am trying to recursively split my data using a stump tree based on the lmtree function from the partykitlibrary. The idea is the following: [1] for each varia

how to get the slope of a linear regression line using c++?

I need to attain the slope of a linear regression similar to the way the Excel function in the below link is implemented: http://office.microsoft.com/en-gb/ex

R SUR regression with systemfit gets error "LU computationally singular: ratio of extreme..." can work around but still concerned about error margins

Before I get into the problem, I want to acknowledge that I have seen that there is a previous question that has been answered, and it gave me an idea for a wor

Reading coef value from OLS regression results

I use pandas and statsmodels to do linear regression. However, i can't find any possible way to read the results. the results are displayed but i need to do som

"Input contains NaN, infinity or a value too large for dtype('float64')"

I am trying to train a model, but I am getting this error Input contains NaN, infinity or a value too large for dtype('float64'). Here's part of my code, how

NameError: name 'predictions' is not defined

i am running the below code and getting this error. Please help: Error: NameError: name 'predictions' is not defined Code: import pandas as pd import numpy a

How to test my trained Tensor Flow model

I currently have a regression model that tries to predict a value based on 25 other ones. Here is the code I currently gave import tensorflow as tf import n