heikkilevanto / beertracker

Simple script to track the beers I drink
GNU General Public License v2.0
2 stars 1 forks source link

Graph not right #159

Closed heikkilevanto closed 3 years ago

heikkilevanto commented 3 years ago

Today the week sum is supposed to be 4.03397327310371 but the graph looks more like 4.5 image

heikkilevanto commented 3 years ago

Verified by plotting constant numbers, they do not match the legend

Aha, IU moved the legend to right side of the curve some time ago, using y2tics etc. That seems to break it. Moving to the left plots right.

It has something to do with the automatic scaling of the graph, when I have ytics, it scales so that a tic is visible. Without ytics, it scales the by the largest value directly.

The solution was to plot ytics with an empty format, so it plots the tick marks without numbers, and y2tics without a format, or with a format like %2.0f