這篇博客很全面html
http://www.cnblogs.com/cdeng/p/3471527.htmlweb
針對預測值和真實值之間的關係,咱們能夠將樣本分爲四個部分,分別是:算法
真正例(True Positive,TP):預測值和真實值都爲1post
假正例(False Positive,FP):預測值爲1,真實值爲0google
真負例(True Negative,TN):預測值與真實值都爲0url
假負例(False Negative,FN):預測值爲0,真實值爲1spa
咱們將這四種值用矩陣表示(圖片引自《machine learning:A Probabilistic Perspective》):.net
上面的矩陣就是混淆矩陣。翻譯
經過混淆矩陣,咱們能夠獲得真正例率(True Positive Rate , TPR):3d
咱們還能夠獲得假正例率(False Positive Rate , FPR):
能夠看到,TPR也就是咱們所說的召回率,那麼只要給定一個決策邊界閾值,咱們能夠獲得一個對應的TPR和FPR值,然而,咱們不從這個思路來簡單的獲得TPR和FPR,而是反過來獲得對應的
,咱們檢測大量的閾值
,從而能夠獲得一個TPR-FPR的相關圖,以下圖所示(圖片引自《machine learning:A Probabilistic Perspective》):
圖中的紅色曲線和藍色曲線分別表示了兩個不一樣的分類器的TPR-FPR曲線,曲線上的任意一點都對應了一個值。該曲線就是ROC曲線(receiver operating characteristic curve)。該曲線具備如下特徵:
從圖中能夠看出,紅色曲線所表明的分類器效果好於藍色曲線所表示的分類器。
參考:
1.《machine learning:A Probabilistic Perspective》
2.wiki
這篇博客只給了算法,未給出理由
http://blog.csdn.net/hanlin_tan/article/details/39183843
最近在作視頻中目標檢測,看到論文中有一項指標叫EER(Equal Error Rate),因而我也想算一算,結果google、baidu了半天,各類百科裏沒有一個像樣的定義,更別提如何計算了。最後在一個matlab論壇裏找到了正解:
「the Equal Error Rate (EER) is the point on the ROC curve that corresponds to have an equal probability of miss-classifying a positive or negative sample. This point is obtained by intersecting the ROC curve with a diagonal of the unit square. 」
翻譯過來就是:EER是(一個分類器的)ROC曲線(接受者操做特性曲線)中錯分正負樣本機率相等的點(所對應的錯分機率值)。這個點就是ROC曲線與ROC空間中對角線([0,1]-[1,0]連線)的交點(以下圖所示)。
因此下圖表示的分類器的EER應該是藍色虛線和紅色ROC曲線的交點對應的橫座標值,在0.17左右。
(關於什麼是ROC曲線,請你們點連接看維基百科吧。)
http://blog.csdn.net/lcmssd/article/details/30803517
ERR 是 Bayesian決策中最佳閾值對應的錯誤率,此時False acceptance 和 False rejection是相等的,
http://www.webopedia.com/TERM/E/equal_error_rate.html
Abbreviated as EER. A biometric security system predetermines the threshold values for its false acceptance rate and its false rejection rate, and when the rates are equal, the common value is referred to as the equal error rate. The value indicates that the proportion of false acceptances is equal to the proportion of false rejections. The lower the equal error rate value, the higher the accuracy of the biometric system.