WholeSkyPlot

class lsst.analysis.tools.actions.plot.WholeSkyPlot(*args, **kw)

Bases: PlotAction

Plots the on sky distribution of a parameter.

Plots the values of the parameter given for the z axis according to the positions given for x and y. Optimised for use with RA and Dec. Also calculates some basic statistics and includes those on the plot.

The default axes limits and figure size were chosen to plot HSC PDR2.

Attributes Summary

autoAxesLimits

Find axes limits automatically.

colorBarRange

The multiplier for the color bar range.

divergentColorMap

List of hexidecimal colors for a divergent color map.

figureSize

Size of the figure.

keyBands

Band for each metric, if any.

plotKeys

Names of metrics to plot.

sequentialColorMap

List of hexidecimal colors for a sequential color map.

sequentialMetrics

Partial names of metrics with sequential values.

xAxisLabel

Label to use for the x axis.

xLimits

Plotting limits for the x axis.

yAxisLabel

Label to use for the y axis.

yLimits

Plotting limits for the y axis.

Methods Summary

__call__(data, **kwargs)

Call self as a function.

getInputSchema(**kwargs)

Return the schema an AnalysisAction expects to be present in the arguments supplied to the __call__ method.

getOutputNames([config])

Returns a list of names that will be used as keys if this action's call method returns a mapping.

makePlot(data[, plotInfo])

Make a skyPlot of the given data.

Attributes Documentation

autoAxesLimits

Find axes limits automatically. (bool, default True)

colorBarRange

The multiplier for the color bar range. The max/min range values are: median +/- N * sigmaMad, where N is this config value. (float, default 3.0)

divergentColorMap

List of hexidecimal colors for a divergent color map. (List, default ['#9A6E3A', '#C6A267', '#A9A9A9', '#4F938B', '#2C665A'])

figureSize

Size of the figure. (List, default [9.0, 3.5])

keyBands

Band for each metric, if any. (List, default None)

plotKeys

Names of metrics to plot. (List, default None)

sequentialColorMap

List of hexidecimal colors for a sequential color map. (List, default ['#F5F5F5', '#5AB4AC', '#284D48'])

sequentialMetrics

Partial names of metrics with sequential values. This is a placeholder until metric information is available via yaml. (List, default ['count', 'num', 'igma', 'tdev', 'Repeat'])

xAxisLabel

Label to use for the x axis. (str, default 'RA (degrees)')

xLimits

Plotting limits for the x axis. (List, default [-5.0, 365.0])

yAxisLabel

Label to use for the y axis. (str, default 'Dec (degrees)')

yLimits

Plotting limits for the y axis. (List, default [-10.0, 60.0])

Methods Documentation

__call__(data: MutableMapping[str, ndarray[Any, dtype[_ScalarType_co]] | Scalar | HealSparseMap | Tensor | Mapping], **kwargs) Mapping[str, Figure] | Figure

Call self as a function.

getInputSchema(**kwargs) Mapping]]]

Return the schema an AnalysisAction expects to be present in the arguments supplied to the __call__ method.

Returns:
resultKeyedDataSchema

The schema this action requires to be present when calling this action, keys are unformatted.

getOutputNames(config: Config | None = None) Iterable[str]

Returns a list of names that will be used as keys if this action’s call method returns a mapping. Otherwise return an empty Iterable.

Parameters:
configlsst.pex.config.Config, optional

Configuration of the task. This is only used if the output naming needs to be config-aware.

Returns:
resultIterable of str

If a PlotAction produces more than one plot, this should be the keys the action will use in the returned Mapping.

makePlot(data: MutableMapping[str, ndarray[Any, dtype[_ScalarType_co]] | Scalar | HealSparseMap | Tensor | Mapping], plotInfo: Mapping[str, str] | None = None, **kwargs) Figure

Make a skyPlot of the given data.

Parameters:
dataKeyedData

The catalog to plot the points from.

plotInfodict

A dictionary of information about the data being plotted with keys:

"run"

The output run for the plots (str).

"skymap"

The type of skymap used for the data (str).

"filter"

The filter used for this data (str).

"tract"

The tract that the data comes from (str).

Returns:
resultsdict

A dictionary containing the resulting figures.

Examples

An example of the plot produced from this code is here:

../_images/wholeSkyPlotExample.png

For a detailed example of how to make a plot from the command line please see the getting started guide.