Check out the Hyperspy Workshop May 13-17, 2024 Online

angular_slice_radial_average#

Diffraction2D.angular_slice_radial_average(angleN=20, centre_x=None, centre_y=None, slice_overlap=None, show_progressbar=True)[source]#

[Deprecated] Do radial average of different angular slices. Useful for analysing anisotropy in round diffraction features, such as diffraction rings from polycrystalline materials or higher order Laue zone rings.

Parameters:
  • angleN (int, default 20) – Number of angular slices. If angleN=4, each slice will be 90 degrees. The average will start in the top left corner (0, 0) when plotting using s.plot(), and go clockwise.

  • centre_x, centre_y (int or NumPy array, optional) – If given as int, all the diffraction patterns will have the same centre position. Each diffraction pattern can also have different centre position, by passing a NumPy array with the same dimensions as the navigation axes. Note: in either case both x and y values must be given. If one is missing, both will be set from the signal (0., 0.) positions. If no values are given, the (0., 0.) positions in the signal will be used.

  • slice_overlap (float, optional) – Amount of overlap between the slices, given in fractions of angle slice (0 to 1). For angleN=4, each slice will be 90 degrees. If slice_overlap=0.5, each slice will overlap by 45 degrees on each side. The range of the slices will then be: (-45, 135), (45, 225), (135, 315) and (225, 45). Default off: meaning there is no overlap between the slices.

  • show_progressbar (bool) – Default True

Returns:

signal – With one more navigation dimensions (the angular slices) compared to the input signal.

Return type:

HyperSpy 1D signal

Examples

>>> s = pxm.data.dummy_data.get_holz_simple_test_signal()
>>> s_com = s.center_of_mass(show_progressbar=False)
>>> s_ar = s.angular_slice_radial_average(
...     angleN=10, centre_x=s_com.inav[0].data,
...     centre_y=s_com.inav[1].data, slice_overlap=0.2,
...     show_progressbar=False)
>>> s_ar.plot() 

Notes

Deprecated since version 0.17: Function angular_slice_radial_average() is deprecated and will be removed in version 1.0.0. Use pyxem.signals.diffraction2d.azimuthal_integral2d() instead.