errorrate function

Error rate of the Bayes rule for two-class Gaussian homoscedastic model

Error rate of the Bayes rule for two-class Gaussian homoscedastic model

The optimal error rate of Bayes rule for two-class Gaussian homoscedastic model

errorrate(beta0, beta, pi, mu, sigma)

Arguments

  • beta0: An n×pn\times p matrix where each row represents an individual observation
  • beta: Number of observations.
  • pi: A g-dimensional vector for the initial values of the mixing proportions.
  • mu: A p×gp \times g matrix for the initial values of the location parameters.
  • sigma: A p×pp\times p covariance matrix if ncov=1, or a list of g covariance matrices with dimension p×p×gp\times p \times g if ncov=2.

Returns

  • errval: A vector of error rate.

Details

The optimal error rate of Bayes rule for two-class Gaussian homoscedastic model can be expressed as

err(yj;θ)=π1ϕ{β0+β1Tμ1(β1TΣβ1)12}+π2ϕ{β0+β1Tμ2(β1TΣβ1)12} err(y_j;\theta)=\pi_1\phi\{-\frac{\beta_0+\beta_1^T\mu_1}{(\beta_1^T\Sigma\beta_1)^{\frac{1}{2}}}\}+\pi_2\phi\{\frac{\beta_0+\beta_1^T\mu_2}{(\beta_1^T\Sigma\beta_1)^{\frac{1}{2}}}\}

where ϕ\phi is a normal probability function with mean μi\mu_i and covariance matrix Σi\Sigma_i.

  • Maintainer: Ziyang Lyu
  • License: GPL-3
  • Last published: 2022-10-18

Useful links