plot_sky#
- astroplan.plots.plot_sky(target, observer, time, ax=None, style_kwargs=None, north_to_east_ccw=True, grid=True, az_label_offset=<Quantity 0. deg>, warn_below_horizon=False, style_sheet=None)[source]#
Plots target positions in the sky with respect to the observer’s location.
If a
Axesobject already exists, plots an additional target position on top. Otherwise, creates a newAxesobject with a sky plot.Can pass in a scalar
Timeobject (e.g.Time('2000-1-1')) or an array of length one (e.g.Time(['2000-1-1'])) to get plot at one instance in time. If pass in anTimeobject with multiple instances of time (e.g.Time(['2000-1-1 20:00:00', '2000-1-1 20:30:00'])), target’s position will be shown at each of these times.For examples with plots, visit the documentation of Sky Charts.
- Parameters:
- target
FixedTarget The celestial body of interest.
- observer
Observer The person, telescope, observatory, etc. doing the observing.
- time
Time If pass in an
Timeobject with just one instance in time, whether it be a scalar or an array (e.g.Time('2000-1-1'),Time(['2000-1-1']),[Time('2000-1-1')]),plot_skywill return plot at one instance in time. If pass in anTimeobject with multiple instances in time (e.g.Time(['2000-1-1', '2000-1-2'])) will show positions plotted at the exact times specified.- ax
Axesor None, optional. The
Axesobject to be drawn on. If None, uses the currentAxes.- style_kwargsdict or None, optional.
A dictionary of keywords passed into
scatterto set plotting styles.- north_to_east_ccwbool, optional.
True by default, meaning that azimuth is shown increasing counter-clockwise (CCW), or with North at top, East at left, etc. To show azimuth increasing clockwise (CW), set to False.
- gridbool, optional.
True by default, meaning that grid is drawn.
- az_label_offset
~astropy.units.degree, optional. DANGER: It is not recommended that you change the default behavior, as to do so makes it seem as if N/E/S/W are being decoupled from the definition of azimuth (North from az = 0 deg., East from az = 90 deg., etc.). An offset for azimuth labels from the North label. A positive offset will increase in the same direction as azimuth (see
north_to_east_ccwoption).- warn_below_horizonbool, optional
If
False, don’t show warnings when attempting to plot targets below the horzion.- style_sheetdict or
None(optional) matplotlib style sheet to use. To see available style sheets in astroplan, print astroplan.plots.available_style_sheets. Defaults to the light theme.
- target
- Returns:
- An
Axesobject (ax) with a map of the sky.
- An
Notes
- Using
Timeobjects: See Astropy documentation for more details.
Coordinate defaults:
Altazimuth (local horizon) coordinate system. North is always at top of plot, South is always at the bottom, E/W can be right or left depending on the
north_to_east_cwoption.Altitude: 90 degrees (zenith) is at plot origin (center) and 0 degrees (horizon) is at plot edge. This cannot be changed by user.
Azimuth: 0 degrees is at North (top of plot), 90 degrees at East, etc. DANGER: Azimuth labels can be changed by user via the
az_label_offsetoption, but it is not recommended, as to do so makes it seem as if N/E/S/W are being decoupled from the definition of azimuth (North from az = 0 deg., East from az = 90 deg., etc.).