bayeslite
bayeslite copied to clipboard
Implement BQL syntax for multiple/joint imputation
Currently
INFER EXPLICIT PREDICT x, PREDICT y FROM p
imputes x
and y
from their marginals. We need BQL syntax for imputing from the joint distribution
INFER EXPLICIT PREDICT (x,y), PREDICT y FROM p
There are non-trivial UI and implementation questions here -- i.e. how does the result look in a tabular form, since the first PREDICT
is bivariate input-output which is not standard SQL.
I recall @riastradh-probcomp did some enormous hack to get PREDICT ... CONFIDENCE
working.
Of course a user can always manually impute using SIMULATE x, y GIVEN z FROM p
which returns results from the specified distribution {x,y}|z
, and then post-process in their favorite way. But BayesDB (or as it stands now IBayesDBMetamodel) should also have some default imputation strategy based on the stattypes.