Can you do linear regression with discrete data?

Can you do linear regression with discrete data?

If you have a discrete variable, you can decide whether to treat it as a continuous or categorical predictor. A discrete variable can be measured and ordered but it has a countable number of values. If you have one continuous predictor, you can use Simple Regression.

How do you predict a regression equation in Excel?

Run regression analysis

  1. On the Data tab, in the Analysis group, click the Data Analysis button.
  2. Select Regression and click OK.
  3. In the Regression dialog box, configure the following settings: Select the Input Y Range, which is your dependent variable.
  4. Click OK and observe the regression analysis output created by Excel.

Which is the best regression for discrete values?

You have some set of features X and a continuous prediction y. There are many regression models to use, linear regression (using ordinary least squares) is one. Scikit-learn has various regression models to choose and tune, and you can find more on their site.

How are regression problems and classification problems related?

There are regression problems and classification problems. Basically, given some features (discrete (car model) or continuous (Miles per Gallon)) you want to estimate the price (a continuous variable). Your model will use the independent variables (your features) to estimate the dependent variable.

When to use logistic regression for percentages and counts?

One key consideration is the dependent variable. For linear models, the dependent variable doesn’t have to be normally distributed, but it does have to be continuous, unbounded, and measured on an interval or ratio scale. Percentages don’t fit these criteria. Yes, they’re continuous and ratio scale.

How to predict model in Statsmodels discrete model?

Call self.model.predict with self.params as the first argument. Remove data arrays, all nobs arrays from result and model. Save a pickle of this instance. Set the fit options for the Null (constant-only) model.