flagManual is too complicated
The process of setting pre-existing flags via flagManual
is a confusing parameter fine tuning experience. It has far too much (poorly documented) necessary parameters with all sorts of inner dependencies and it needs far too much frustrating try-out for such a basic task.
I get that there can be a vast manifold of formats pre-existing flags can come in and also the intentions of what exactly to flag (interval or on-point) can widely differ. Never the less, there should be some automatic default interpretations of the passed data in the most common contexts, since usually its clear from the format what behavior is desired:
- passing just a list/array of time stamps to
mdata
should automatically be interpreted as the task to just set theflag
-value at those timestamps - passing a list-like of tuples of timestamps should just be interpreted as flagging all data in between those timestamps (with the defaultly set closure behavior)
- passing a Series-like that is not date time valued, should just trigger setting the passed series values as flags at the passed timestamps (and throw an error if those are not interpretable as such)
- passing a Series-like that is date time valued should just trigger flagging the intervals between the index value and the data value (with the closure behavior defaultly set)
and of course, by changing the defaults of the parameters one can enforce differing interpretations