Warning

You are reading the documentation related to the development version. Go here if you are looking for the documentation of the stable release.

spectrochempy.ptp

ptp(dataset, dim=None, keepdims=False)[source]

Range of values (maximum - minimum) along a dimension.

The name of the function comes from the acronym for ‘peak to peak’ .

Parameters
  • dim (None or int or dimension name, optional) – Dimension along which to find the peaks. If None, the operation is made on the first dimension.

  • keepdims (bool, optional) – If this is set to True, the dimensions which are reduced are left in the result as dimensions with size one. With this option, the result will broadcast correctly against the input dataset.

Returns

ptp – A new dataset holding the result.