Medical Diagnosis

1 minute read

Medical Diagnosis

  • Dermatalogy - Deals with skin diseases
  • Opthalmology - Deals with diagnoses and treatment of eye disorders.
  • Histopathology - Medical speciality involving examining of tissue under the microscope. [study involves is to check the cancer spread]

Evaluations

  • Evaluation Metrics:
    • How good is a model : \(Accuracy = \dfrac{Examples\ correctly \ classified} {Total\ number\ of\ examples}\)
    • Accuracy in terms of conditional probability
      • could be defined as : \(Accuracy = P(correct)\)
      • Well, the above is not always correct; because it could be biased if multiple labels are there, so it can be modified as : \(Accuracy = P(correct\ \cap \ disease) + P(correct\ \cap \ normal)\)
      • Law of conditional probability \(P(A \cap B) = P(A|B)P(B)\) So, the above accuracy can be defined as : \(Accuracy = P(correct|disease)P(disease) + P(correct|normal)P(normal)\) \(Accuracy = P(+|disease)P(disease) + P(-|normal)P(normal)\)
      • Sensitivity - true positive rate
      • Specificity - true negative rate
      • Sensitivity - It is the probability that the model classify the patient is having a disease given that they have the disease.
      • Specificity - It is the probability that the model classify the patient as being normal given that they are normal
      • So the accuracy would be defined as : \(Accuracy = Sensitivity\ * \ P(disease) + Specificity \ * \ P(normal)\) \(Accuracy = Sensitivity * prevalence + Specificity * (1 - prevalence)\)
      • Sensitivity and Specificity can be computed as : \(P(+|disease) = sensitivity = \dfrac{\#(+\ and\ disease)}{\#(disease)}\) \(P(-|normal) = specificity = \dfrac{\#(-\ and\ normal)}{\#(normal)}\)
      • Prevalence can be computed as : \(prevalence = P(disease) = \dfrac{\#(disease)} {\#(total)}\)
      • PPV (Positive Predictive Value) - If a model prediction is positive, what is the probability that a patient has a disease: \(P(disease\ |\ +)\)
      • NPV (Negative Predictive Vlaue) - If a model prediction is negative, what is the probability that a patient is normal: \(P(normal\ |\ -)\)
      • PPV & NPV \(PPV = P(disease|+) = \dfrac{\#(+\ and\ disease)}{\#(+)}\) \(NPV = P(normal|-) = \dfrac{\#(-\ and\ normal)}{\#(-)}\)
      • Confusion Matrix:
      Disease True Positive False Negative
      Normal False Positive True Negative

      \(Sensitivity = \dfrac{TP}{TP\ + \ FN}\) \(Specificity = \dfrac{FP}{FP\ +\ TN}\) \(PPV = \dfrac{TP}{TP\ + \ FP}\) \(NPV = \dfrac{FN}{FN\ + \ TN}\)

      • Another way of computing PPV: \(PPV = \dfrac{sensitivity * prevalence}{(sensitivity * prevalence)+((1-specificity)*(1-prevalence))}\)

Segmentation

  • Image Segmentation
    • Soft Dice Loss of image segmentation problem \(L(P,G) = 1 - \dfrac{2\sum_i^n p_ig_i}{\sum_i^n p_i^2 + \sum_i^n g_i^2}\)
    • P is predicted value & G is ground truth value