Skip to content

CHAP saxswaxs documentation request: Example of using CHAP library to import to a dataset to xarray with axes #267

@arwoll

Description

@arwoll

On the documentation for the CHAP saxswaxs module, I request an example of the use of the CHAP libraries to locate and import a specific dataset from a nexpy file into an xarray. (this solidifies a general discussion we have had for some time).

A specific dataset I suggest testing with would be one of the "vs_time" data sets obtained by the Dufresne group, e.g. /nfs/chess/auxiliary/reduced_data/cycles/2026-1/id3b/dufresne-4795-a/analysis/vs_time/MR3-Kinetics/MR3-3_I100_0to5min_flymesh_001.nxs. (though the specific path/data should be omitted from the online version).

What I envision is a snippet of python code along the lines of:

from CHAP.... import nxobject_to_xarray
from CHAP.... import list_nxprocesses

nexusfile = 'test.nxs'
list_nxprocesses(nexusfile)

identify desired dataset, e.g. /data/waxs_radial_flux_norm_bkgd_corrected

dataarray = nxobject_to_xarray(nexusfile, '/data/waxs_radial_flux_norm_bkgd_corrected')

Metadata

Metadata

Assignees

Labels

documentationImprovements or additions to documentationsaxswaxsRelated to CHAP.saxswaxs

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions