    (p/init! samp (srand-int))))
 
 (defn histogram!
-  ([estimator n]
+  ([estimator ^long n]
    (p/histogram! estimator n)))
 
 (defn histogram

(defn evidence ^double [dist xs]
  (if (compatible? dist (p/data xs))
    (p/evidence (p/engine dist) (p/parameters dist) (p/data xs))
    (format "Incompatible xs: %s." (type xs))))

;; ================= Estimation ===============================================


(defn pdf [dist xs]
  (if (compatible? dist (p/data xs))
    (p/pdf (p/engine dist) (p/parameters dist) (p/data xs))
    (dragan-says-ex (format "Data type is incompatible with distribution engine"
                            {:type (type dist) :factory (info (p/data xs))}))))

;;TODO rename to log-pd or log-density
(defn log-pdf [dist xs]
  (if (compatible? dist (p/data xs))
    (p/log-pdf (p/engine dist) (p/parameters dist) (p/data xs))
    (dragan-says-ex (format "Data type is incompatible with distribution engine"
                            {:type (type dist) :factory (info (p/data xs))}))))

(defn likelihood [lik xs]
  (throw (UnsupportedOperationException. "TODO")))
