diff options
author | Christoph Helma <helma@in-silico.ch> | 2011-08-22 16:23:00 +0000 |
---|---|---|
committer | Christoph Helma <helma@in-silico.ch> | 2011-08-22 16:23:00 +0000 |
commit | f5eccd4ce22acb2fa05e84fb80e8385cce235d51 (patch) | |
tree | 1d4c76cf4a40bc60761c0dc2a201bc15e1847d9e | |
parent | 8656f259932b03c3ddf7f5eff755d70ab7fbe3eb (diff) |
NA inserted if valdiation parameters missing
-rw-r--r-- | views/classification_validation.haml | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/views/classification_validation.haml b/views/classification_validation.haml index 47e1f75..e06cb65 100644 --- a/views/classification_validation.haml +++ b/views/classification_validation.haml @@ -5,13 +5,24 @@ %dt %a{:href => "http://en.wikipedia.org/wiki/Receiver_operating_characteristic", :rel => "external"} Average area under ROC: %dd - = sprintf("%.3f", model.average_area_under_roc.to_f) if model.average_area_under_roc + - if model.average_area_under_roc + = sprintf("%.3f", model.average_area_under_roc.to_f) + - else + = 'NA' %dt %a{:href => "http://en.wikipedia.org/wiki/Sensitivity_and_specificity", :rel => "external"} Specificity: -%dd= sprintf("%.3f", model.specificity.to_f) if model.specificity +%dd + - if model.specificity + = sprintf("%.3f", model.specificity.to_f) + - else + = 'NA' %dt %a{:href => "http://en.wikipedia.org/wiki/Sensitivity_and_specificity", :rel => "external"} Sensitivity: -%dd= sprintf("%.3f", model.sensitivity.to_f) if model.sensitivity +%dd + - if model.sensitivity + = sprintf("%.3f", model.sensitivity.to_f) + - else + = 'NA' %dt %a{:href => "http://en.wikipedia.org/wiki/Confusion_matrix", :rel => "external"} Confusion Matrix: - if model.confusion_matrix |