figures contains functions for plotting alert and history data.


Adapted from:

pgb_utils.pgb_utils.figures.plot_lightcurve(dflc, objectId=None, ax=None, days_ago=True)[source]

Plot the lighcurve (per band) of a single ZTF object. Adapted from:

  • dflc (DataFrame) – Lightcurve history of a unique objectId. Must contain columns [‘jd’,’fid’,’magpsf’,’sigmapsf’,’diffmaglim’]

  • objectId (Optional[str]) – objectId identifying dflc. Used for plot title.

  • ax (Optional[Axes]) – matplotlib axes for the figure. If None, a new figure will be created

  • days_ago (bool) – If True, x-axis will be number of days in the past. Else x-axis will be Julian date.


Adapted from:

pgb_utils.pgb_utils.figures.plot_stamp(stamp, fig=None, subplot=None, **kwargs)[source]

Adapted from: