Skip to content

Commit

Permalink
Allow the line width to be specified for limit lines
Browse files Browse the repository at this point in the history
  • Loading branch information
jzuhone committed Nov 13, 2023
1 parent 32f26d9 commit 9af3f22
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions acis_thermal_check/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ def __init__(
self.ax2 = ax2
self.filename = None

def add_limit_line(self, limit, ls="-"):
def add_limit_line(self, limit, ls="-", lw=2):
"""
Add a horizontal line for a given limit to the plot.
Expand All @@ -266,6 +266,8 @@ def add_limit_line(self, limit, ls="-"):
the color it should be plotted with, and its label.
ls : string, optional
The line style for the limit line. Default: "-"
lw : float, optional
The line width for the limit line. Default: 2.0
"""
label = limit["display_name"]
# If the label already exists, we shouldn't need to repeat it
Expand All @@ -277,7 +279,7 @@ def add_limit_line(self, limit, ls="-"):
self.ax.axhline(
limit["value"],
linestyle=ls,
linewidth=2.0,
linewidth=lw,
color=limit["color"],
label=label,
zorder=2.0,
Expand Down

0 comments on commit 9af3f22

Please sign in to comment.