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

Add slicing support for category axis #267

Closed
HDembinski opened this issue Jan 3, 2020 · 3 comments
Closed

Add slicing support for category axis #267

HDembinski opened this issue Jan 3, 2020 · 3 comments

Comments

@HDembinski
Copy link
Collaborator

category axes are currently not sliceable (see reduce algorithm), because slicing didn't seem to make sense for category axes.

However,
scikit-hep/boost-histogram#296
suggests that also category axis should be sliceable, and eventually one should be able to pick individual bin indices as well. Perhaps using the keyword pick(index1, index2, ...) as suggested by @henryiii

@henryiii
Copy link
Contributor

henryiii commented Jan 3, 2020

Note on pick: you need both an index and an axes number, since the difference with .at() is that you will leave some axes alone and get a histogram back. Or some way to indicate that an axes should be kept. It would be quite useful for integer (+boolean) axes and category axes, I believe.

@HDembinski
Copy link
Collaborator Author

The patch for making category axis sliceable is almost done
HDembinski#103

@HDembinski
Copy link
Collaborator Author

closed in develop

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

No branches or pull requests

2 participants