Skip to content

Minor issues with History #57

@JoseKling

Description

@JoseKling

1 - Field types

Right now, h = History([0.5], ["a"], 0, 1) does not work, since the same type must be used in times, tmin and tmax.
Any reason to not make times, tmin and tmax all take Float64 and let the arguments be automatically converted?

2 - Add checks?

The constructor should probably check if all the events are inside the interval [tmin, tmax], it times is sorted and if times and marks have the same length.

3 - Non-marked history

Probably makes sense to have a separate constructor for non-marked history History(times, tmin, tmax). Methods like event_marks and max_marks should have separate implementations, maybe just returning nothing?

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions