Similar to @seealso estimatePdf, this function returns
the probability for a discrete value, given some observations.
getProbForDiscrete(data, value)
| data | vector of observations that have the same type as the given value.  | 
    
|---|---|
| value | a single observation of the same type as the data vector.  | 
    
the probability of value given data.
If no observations are given, then this function will warn and return a probability of zero for the value given. While we could technically return positive infinity, 0 is more suitable in the context of Bayesian inferencing.
#> Warning: No data was given for calculating probability for discrete value.#> [1] 0mmb::getProbForDiscrete(data = iris$Species, value = iris[1,]$Species)#> [1] 0.3333333