Skip to content

Commit 986f5fc

Browse files
committed
Escape absolute values
1 parent 8d6ced7 commit 986f5fc

1 file changed

Lines changed: 19 additions & 19 deletions

File tree

sasdata/data_util/averaging.py

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -273,8 +273,8 @@ def __call__(self, data2d: Data2D) -> Data1D:
273273

274274

275275
class CircularAverage(PolarROI):
276-
"""
277-
Calculate I(|Q|) by circularly averaging 2D data between 2 radial limits.
276+
r"""
277+
Calculate I(\|Q\|) by circularly averaging 2D data between 2 radial limits.
278278
279279
This class is initialised by specifying lower and upper limits on the
280280
magnitude of Q values to consider during the averaging, though currently
@@ -290,13 +290,13 @@ def __init__(
290290
nbins: int = 100,
291291
base: float | None = None,
292292
) -> None:
293-
"""
293+
r"""
294294
Set up the lower and upper radial limits as well as the number of bins.
295295
296296
The units are A^-1 for the radial parameters.
297-
:param r_min: Lower limit for |Q| values to use during averaging.
298-
:param r_max: Upper limit for |Q| values to use during averaging.
299-
:param nbins: The number of bins data is sorted into along |Q| the axis
297+
:param r_min: Lower limit for \|Q\| values to use during averaging.
298+
:param r_max: Upper limit for \|Q\| values to use during averaging.
299+
:param nbins: The number of bins data is sorted into along \|Q\| the axis
300300
"""
301301
super().__init__(r_range=r_range, center=center)
302302
self.nbins: int = nbins
@@ -396,12 +396,12 @@ def __init__(
396396
nbins: int = 100,
397397
base: float | None = None,
398398
) -> None:
399-
"""
399+
r"""
400400
Set up the lower and upper radial limits as well as the number of bins.
401401
402402
The units are A^-1 for the radial parameters.
403-
:param r_min: Lower limit for |Q| values to use during averaging.
404-
:param r_max: Upper limit for |Q| values to use during averaging.
403+
:param r_min: Lower limit for \|Q\| values to use during averaging.
404+
:param r_max: Upper limit for \|Q\| values to use during averaging.
405405
:param nbins: The number of bins data is sorted into along Phi the axis
406406
"""
407407
super().__init__(r_range=r_range, center=center)
@@ -549,7 +549,7 @@ def __call__(self, data2d: Data2D = None) -> Data1D:
549549

550550

551551
class SectorQ(PolarROI):
552-
"""
552+
r"""
553553
Project I(Q, φ) data onto I(Q) within a region defined by Cartesian limits.
554554
555555
The projection is computed by averaging together datapoints with the same
@@ -558,7 +558,7 @@ class SectorQ(PolarROI):
558558
559559
This class is initialised by specifying lower and upper limits on both the
560560
magnitude of Q and the angle φ. These four parameters specify the primary
561-
Region Of Interest, however there is a secondary ROI with the same |Q|
561+
Region Of Interest, however there is a secondary ROI with the same \|Q\|
562562
values on the opposite side of the origin (φ + π). How this secondary ROI
563563
is treated depends on the value of the `fold` parameter. If fold is set to
564564
True, data on opposite sides of the origin are averaged together and the
@@ -579,14 +579,14 @@ def __init__(
579579
fold: bool = True,
580580
base: float | None = None,
581581
) -> None:
582-
"""
582+
r"""
583583
Set up the ROI boundaries, the binning of the output 1D data, and fold.
584584
585585
The units are A^-1 for radial parameters, and radians for anglar ones.
586-
:param r_range: Tuple (r_min, r_max) defining limits for |Q| values to use during averaging.
586+
:param r_range: Tuple (r_min, r_max) defining limits for \|Q\| values to use during averaging.
587587
:param phi_range: Tuple (phi_min, phi_max) defining limits for φ in radians (in the primary ROI).
588588
:Defaults to full circle (0, 2*pi).
589-
:param nbins: The number of bins data is sorted into along the |Q| axis
589+
:param nbins: The number of bins data is sorted into along the \|Q\| axis
590590
:param fold: Whether the primary and secondary ROIs should be folded
591591
together during averaging.
592592
"""
@@ -709,14 +709,14 @@ def __init__(
709709
nbins: int = 100,
710710
base: float | None = None,
711711
) -> None:
712-
"""
712+
r"""
713713
Set up the ROI boundaries, and the binning of the output 1D data.
714714
715715
The units are A^-1 for radial parameters, and radians for anglar ones.
716-
:param r_range: Tuple (r_min, r_max) defining limits for |Q| values to use during averaging.
716+
:param r_range: Tuple (r_min, r_max) defining limits for \|Q\| values to use during averaging.
717717
:param phi_range: Tuple (phi_min, phi_max) defining limits for φ in radians (in the primary ROI).
718718
:Defaults to full circle (0, 2*pi).
719-
:param nbins: The number of bins data is sorted into along the |Q| axis
719+
:param nbins: The number of bins data is sorted into along the \|Q\| axis
720720
"""
721721
super().__init__(r_range=r_range, phi_range=phi_range, center=center)
722722
self.nbins: int = nbins
@@ -791,11 +791,11 @@ def __init__(
791791
nbins: int = 100,
792792
base: float | None = None,
793793
) -> None:
794-
"""
794+
r"""
795795
Set up the ROI boundaries, and the binning of the output 1D data.
796796
797797
The units are A^-1 for radial parameters, and radians for anglar ones.
798-
:param r_range: Tuple (r_min, r_max) defining limits for |Q| values to use during averaging.
798+
:param r_range: Tuple (r_min, r_max) defining limits for \|Q\| values to use during averaging.
799799
:param phi_range: Tuple (phi_min, phi_max) defining angular bounds in radians.
800800
Defaults to full circle (0, 2*pi).
801801
:param nbins: The number of bins data is sorted into along the φ axis.

0 commit comments

Comments
 (0)