-
-
Notifications
You must be signed in to change notification settings - Fork 8
Description
There used to be a transform
argument to plotting functions (maybe some stats too) which wasn't too useful as it only allowed a callable. I propose to instead create a transform helper.
def transform(idata, transform_funcs=None, group="posterior", return_dataset=False):
if transform_funcs is None:
transform_funcs = {}
# loop over variables in `group` and check
# 1) if there is a transform function mapped to it
# 2) if there are transformed values in the unconstrained group use that
Thus, without arguments it would combine the samples in posterior and unconstrained posterior to have all the samples in the unconstrained space. Not 100% sure about how the output should look like. I think it would be useful to allow returning that dataset directly, but it should also return a modified inferencedata/datatree, maybe with the unconstrained_posterior group but no posterior group? or viceversa which might play nicer with defaults in the rest of the functions?
Also, feel free to propose other names, I don't think transform is a particularly good choice as it is too general, maybe get_unconstrained_samples
is more clear?
Metadata
Metadata
Assignees
Labels
Type
Projects
Status