Skip to content

Commit

Permalink
Include change point attributes in JSON output
Browse files Browse the repository at this point in the history
Co-authored-by: Henrik Ingo <[email protected]>
  • Loading branch information
mfleming and henrikingo committed Mar 15, 2024
1 parent 803f916 commit d107f05
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion hunter/series.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,11 @@ class ChangePointGroup:
changes: List[ChangePoint]

def to_json(self):
return {"time": self.time, "changes": [cp.to_json() for cp in self.changes]}
return {
"time": self.time,
"attributes": self.attributes,
"changes": [cp.to_json() for cp in self.changes],
}


class Series:
Expand Down

0 comments on commit d107f05

Please sign in to comment.