The prob_of_X_given_C function outcomes

Hi,

I would like to request a help about the prob_of_X_given_C function. After to complete the code and ran it, I got the following outcomes:

Example dog has breed 1 and features: height = 28.63, weight = 21.56, bark_days = 13.00, ear_head_ratio = 0.27

Probability of these features if dog is classified as breed 0: [0. 0. 0. 0.]
Probability of these features if dog is classified as breed 1: [0. 0. 0. 0.]
Probability of these features if dog is classified as breed 2: [0. 0. 0. 0.]

Please, any help?

There is a lot going on in this function. Here are a few guidelines:

  • The match inside the for-loop is over the feature names.
  • References to params_dict[.] use the the breed and feature name, and a text string for the appropriate dictionary value (such as “mu”, “sigma”, “n”, “p”, “a”, or “b”).
  • References to a probability function use a feature val and the correct parameters for that probability (found within the same case statement).
  • The final multiplication uses the probability_f value that was computed in each case.

Hi,

I did exactly that. There is no error (syntax) in my coding. How to proceed ?

Regards,

Please check your personal messages for instructions.