多分类逻辑回归模型

假设Y的取值集合是${1, 2, \cdots, K}$,则

P(Y=kx)=exp(wkx)1+k=1K1exp(wkx)P(Y=K)=11+k=1K1exp(wkx)\begin{aligned} P(Y=k|x) = \frac{\exp (w_k \cdot x)}{1+\sum_{k=1}^{K-1}exp(w_k \cdot x)} \\ P(Y=K) = \frac{1}{1+\sum_{k=1}^{K-1}exp(w_k \cdot x)} \end{aligned}

其中$x \in R^{n+1}$,$w_k \in R^{n+1}$

Last updated