erdogant / bnlearn

Python library for learning the graphical structure of Bayesian networks, parameter learning, inference and sampling methods.
https://erdogant.github.io/bnlearn
Other
463 stars 45 forks source link

Missing data #81

Open PARODBE opened 1 year ago

PARODBE commented 1 year ago

Hi,

One question, the library have any option for missing data computation like bnlearn of R?

Thanks!

erdogant commented 1 year ago

There are no imputation functions for missing data. But if you create a function that does it (without a lot of dependencies of other packages), feel free to push it!

harrietmwwright commented 1 year ago

Im also looking for this functionality. At the moment if you are trying to make a prediction on a dataset and remove one of the variables it will make the prediction, however, it will error if you provide the variable with a value of NaN. Is this doing some sort of imputation/estimation in the backend?

PARODBE commented 1 year ago

we can use bayes theorem and with the computed posteriors removed from the equation missing data?

erdogant commented 1 year ago

Can you maybe make a small example to demonstrate this? Maybe with the sprinkler data set?

PARODBE commented 1 year ago

I know that pymc3 library do this...I have read It in a hierarchical linear regression using bayesian approach, in this moment I don't remember the article, but this blog shows something like that: http://stronginference.com/missing-data-imputation.html