xray-analysis
TypeScript icon, indicating that this package has built-in type declarations

0.3.0 • Public • Published

xray-analysis

NPM version npm download

X-ray analysis package for treatment of an x-ray rocking curve (XRC) and an x-ray diffraction (XRD) measurement

Installation

$ npm i xray-analysis

Usage

export { fromXRD } from 'xray-analysis';

const content = readFileSync(join(__dirname, 'XRD.csv'), 'latin1');
const analysis = fromXRay(content);
const measurement = analysis.measurements[0];
const peaks = measurement.meta?.peaks.map(({ x, y, shape }) => ({
  x, // x-position
  y, // intensity
  width: shape.fwhm, // Full width at half maximum
}));

License

MIT

Package Sidebar

Install

npm i xray-analysis

Weekly Downloads

12

Version

0.3.0

License

MIT

Unpacked Size

21 kB

Total Files

38

Last publish

Collaborators

  • cheminfo-bot