DataSpace2D

class sherpa.data.DataSpace2D(filter, x0, x1)[source] [edit on github]

Bases: object

Class for representing 2-D Data Spaces.

Data Spaces are spaces that describe the data domain.

Parameters
  • filter (Filter) – A filter object that initialized this data space.

  • x0 (array_like) – The first and second axes of this data space. The arrays are copied.

  • x1 (array_like) – The first and second axes of this data space. The arrays are copied.

Attributes Summary

grid

The grid representation of this dataset.

x0

Return the first axis.

x1

Return the second axis.

Methods Summary

get([filter])

Get a filtered representation of this data set.

Attributes Documentation

grid

The grid representation of this dataset.

The x0 and x1 arrays in the grid are one-dimensional representations of the meshgrid obtained from the x and y axis arrays, as in numpy.meshgrid(x, y)[0].ravel()

Returns

(x0, x1) – A tuple representing the x0 and x1 axes.

Return type

(ndarray, ndarray)

x0

Return the first axis.

x1

Return the second axis.

Methods Documentation

get(filter=False)[source] [edit on github]

Get a filtered representation of this data set. If filter is False this object is returned.

Parameters

filter (bool) – whether the data set should be filtered before being returned

Return type

DataSpace2D