STIXMap#
- class stixpy.map.stix.STIXMap(data, header, plot_settings=None, **kwargs)[source]#
Bases:
GenericMapA class to represent a STIX Map.
Attributes Summary
Methods Summary
is_datasource_for(data, header, **kwargs)plot(**kwargs)Plots the map object using matplotlib, in a method equivalent to
imshow()using nearest neighbor interpolation.Attributes Documentation
Methods Documentation
- plot(**kwargs)[source]#
Plots the map object using matplotlib, in a method equivalent to
imshow()using nearest neighbor interpolation.- Parameters:
annotate (
bool, optional) – IfTrue, the data is plotted at its natural scale; with title and axis labels.axes (
Axesor None) – If provided the image will be plotted on the given axes. Else the current Matplotlib axes will be used.title (
str,bool, optional) – The plot title. IfTrue, uses the default title for this map.clip_interval (two-element
Quantity, optional) – If provided, the data will be clipped to the percentile interval bounded by the two numbers.autoalign (
boolorstr, optional) – If other thanFalse, the plotting accounts for any difference between the WCS of the map and the WCS of theWCSAxesaxes (e.g., a difference in rotation angle). Ifpcolormesh, this method will usepcolormesh()instead of the defaultimshow(). SpecifyingTrueis equivalent to specifyingpcolormesh.**imshow_kwargs (
dict) – Any additional imshow arguments are passed toimshow().
Examples
>>> # Simple Plot with color bar >>> aia.plot() >>> plt.colorbar() >>> # Add a limb line and grid >>> aia.plot() >>> aia.draw_limb() >>> aia.draw_grid()
Notes
The
autoalignfunctionality is computationally intensive. If the plot will be interactive, the alternative approach of preprocessing the map (e.g., de-rotating it) to match the desired axes will result in better performance.When combining
autoalignfunctionality withHelioprojectivecoordinates, portions of the map that are beyond the solar disk may not appear, which may also inhibit Matplotlib’s autoscaling of the plot limits. The plot limits can be set manually. To preserve the off-disk parts of the map, using theSphericalScreencontext manager may be appropriate.