obsidian-tracker icon indicating copy to clipboard operation
obsidian-tracker copied to clipboard

Ignore missing values a.k.a. non-daily tracker

Open dasheck0 opened this issue 2 years ago • 6 comments

Is there support for non-daily trackers? For example: I track the size of certain muscles in order to follow progress. I do this every other day and not every day. When I render charts there are gaps between data points. Lines are not drawn, so I have to go with bar charts. However, the more time goes by the narrower get the bars, since most of the days there are no data points. I'd like an option ignoreEmpty where dates are skipped when there is no data for the given date. Is this already possible?

dasheck0 avatar Jul 13 '21 06:07 dasheck0

Parameter fillGap can help you. :)

searchType: ...
searchTarget: ...
line:
    fillGap: true
    ....

pyrochlore avatar Jul 13 '21 07:07 pyrochlore

Amazing. So simple. Thanks :)

EDIT: Does only work for line charts. This is fine for me and solves my problem. Might not be the case for everyone. But until then: Thanks for your help. Closing this ticket

dasheck0 avatar Jul 14 '21 07:07 dasheck0

I can add a parameter skip (accept a number N) to skip data every N days for advanced usage.

pyrochlore avatar Jul 14 '21 07:07 pyrochlore

@pyrochlore Is there a fillGap alternative for the bar chart? to Ignore empty/missing values?

suniluci avatar Jul 18 '21 16:07 suniluci

HI @suniluci,

For parameter fillGap in the line chart, we did not add data to the series but connect data points across days missing values. In the bar chart, there is no such connection between data.

I planed to add custom dataset and function to do interpolation (thus add interpolated data on missing data) in the version next to the next release. Is this feature what you need?

pyrochlore avatar Jul 19 '21 01:07 pyrochlore

Depends on what you can do with the function. This approach might be the most flexible one tho. So looking forward to see what's coming :)

dasheck0 avatar Jul 21 '21 10:07 dasheck0