Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Utility for flattening a Dataset #5

Open
sethaxen opened this issue Aug 20, 2022 · 0 comments
Open

Utility for flattening a Dataset #5

sethaxen opened this issue Aug 20, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@sethaxen
Copy link
Member

Several plots and diagnostics operate only on marginals; as a result, we have a need for a utility function that flattens a Dataset to a single variable with 3dimensions: (chain, draw, var_name). For some variable x with dims (chain, draw, dim1, dim2), dim1=[:a, :b], and dim2=[1, 2], var_name would have dimensions like [x[a,1], x[b, 1], x[a, 2], x[b, 2]].

This utility should have a short name and simple syntax so that it can be used where tables are expected. The return value should be a DimArray. Alternatively, a subset of variables to be flattened could be specified, or variables to be flattened independently could be specified. The latter would facilitate making a corner plot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant