Add contiguos edges to TimeMapAxis
@@ -1948,6 +1948,14 @@ class TimeMapAxis:
"""Return array of bin edges min values."""
return self._edges_max
+ @property
+ def edges(self):
+ """Return array of bin edges values."""
+ if not self.is_contiguous:
+ raise ValueError("Time axis is not contiguous")
+
+ return edges_from_lo_hi(self.edges_min, self.edges_max)
+
@property
def time_min(self):
"""Return axis lower edges as Time objects."""
@@ -1968,6 +1976,11 @@ class TimeMapAxis:
"""Return time bin center (`~astropy.time.Time`)."""
return self.time_min + 0.5 * self.time_delta
+ @property
+ def time_edges(self):
+ """Time edges"""
+ return self.reference_time + self.edges
+
@property
def as_xerr(self):
"""Plot x error"""
