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

refactor: add RSoXS package to array using register_dataarray_accessor and register_dataset_accessor #13

Open
pbeaucage opened this issue Jul 26, 2021 · 1 comment
Labels
documentation Improvements or additions to documentation

Comments

@pbeaucage
Copy link
Collaborator

this page details how to register functions as xarray accessors, so that we can just do something to the effect of

import PyHyperScattering.util.RSoXS

array = loader.load(whatever args)

array.rsoxs_ar(chi_width=0)
pbeaucage added a commit that referenced this issue Oct 9, 2021
Add rsoxs class as a dataarray accessor.  Rewrite rsoxs.slice_chi to
handle just about any kind of slice you can throw at it.  Add some unit
tests to rsoxs.slice_chi for kicks.
@pbeaucage
Copy link
Collaborator Author

the syntax is actually array.rsoxs.AR(), but it works.

to-do before closing: update documentation and tutorials to correctly cover this.

@pbeaucage pbeaucage added the documentation Improvements or additions to documentation label May 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

1 participant