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

Improving the HTML representation of InferenceData #10

Open
2 tasks
sethaxen opened this issue Aug 25, 2022 · 0 comments
Open
2 tasks

Improving the HTML representation of InferenceData #10

sethaxen opened this issue Aug 25, 2022 · 0 comments
Labels
help wanted Extra attention is needed

Comments

@sethaxen
Copy link
Member

Python ArviZ has a really nice HTML representation of their InferenceData that expands xarray's own fancy HTML representation of xarray.Datasets. I believe this representation uses both CSS and javascript. You can see it in action here: https://python.arviz.org/en/latest/getting_started/XarrayforArviZ.html

Similarly, we use <details> show the groups of InferenceData and <code> to show the plaintext representation of Dataset. See, for example, https://julia.arviz.org/stable/working_with_inference_data/. The goal of such a representation is to make it easy for IJulia and Pluto users, as well as users of websites that display InferenceData objects, to get a sense for the structure of the data.

There are a few improvements we should consider making:

  • Replace <details> with a <ul> or a <div>, using CSS to style it and potentially JS to control the dropdowns. This prevents sites that have a custom <details> style from breaking the display of InferenceData.
  • Add a fancier HTML representation of Dataset. Something like xarray's that allows previewing of some of the array data or expanding the dimensions would be useful.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant