Multinomial Logistic Regression Calculator

Predict an outcome with three or more categories. Get baseline-category logits, odds ratios, the χ² goodness-of-fit test, pseudo R² and a classification table.

Y is the last column. Leave Y empty on a row to have the model predict it. Everything runs in your browser.

  1. 1. Load the example

    Click Example to fill the table with three groups (A, B, C) and two predictors.

  2. 2. Or enter your data

    Type, or paste from Excel into the first cell. Y is the last column and needs three or more labels.

  3. 3. Choose predictors

    Under each column pick Include (✔/✘) and an optional Transform (Log10, Ln, Sqrt, x²).

  4. 4. Press Calculate

    Nothing runs until you press the button. Results appear in three tabs.

  5. 5. Read the result

    Start with the fit test (p-value) and the classification table, then the odds ratios.

Data — paste from Excel into the first cell, or type

Includeoutcome
Transform
Row
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51

Rows with a Y train the model. Rows with an empty Y are scored and listed in the Classification tab. Rows with an empty or non-numeric predictor are removed.

Enter your data above and press Calculate.

The plain-English guide

Use multinomial logistic regression when the thing you predict is a category with three or more unordered options, such as a customer's plan (Basic, Plus, Pro) or a flower species. The model gives the probability of every category for every row.

Key words, explained simply

Multinomial logit

Logistic regression for an outcome with three or more unordered categories.

Baseline category

The reference outcome. Every other category gets its own equation comparing it to the baseline.

Coefficient (log-odds)

Change in log(P(category)/P(baseline)) when the predictor rises by one unit.

Odds ratio

exp(coefficient). Above 1 the category becomes more likely versus the baseline, below 1 less likely.

Log-likelihood

How well the model explains the data. Closer to 0 (less negative) is better.

χ² goodness of fit

Likelihood-ratio test: is the model better than one that ignores all predictors?

Pseudo R²

McFadden, Cox-Snell and Nagelkerke. Rough 0–1 measures of fit; McFadden 0.2–0.4 is already good.

Ridge (L2) penalty

Shrinks coefficients. Use a small value if groups separate perfectly and the fit will not converge.

How this calculator works

With K categories and baseline category 1, the model fits K−1 equations: log(P(k)/P(1)) = β₀ + β₁X₁ + … . Probabilities come from the softmax of those scores. Coefficients are found by maximum likelihood with Newton-Raphson (optionally with a ridge penalty), standard errors come from the inverse information matrix, and the χ² test compares the model with an intercept-only model.

Special functions (normal and χ² distributions) use standard numerical approximations accurate to about 6 digits, so p-values beyond that are shown as "less than".

Common questions