kristovatlas / address-reuse-tracker

Maintains stats on address reuse in Bitcoin network, displays charts
24 stars 6 forks source link

Skewed right-most tick on chart when resolution > 1 and data above maximum point not available #6

Open kristovatlas opened 8 years ago

kristovatlas commented 8 years ago

For example, if we try to chart blocks 0 to 50 with a resolution of 10 and no data is available for blocks 51+, we'll get:

0-9: ten blocks of data divided by ten blocks 10-19: "" 20-29: "" 30-39: "" 40-49: "" 50-50: one block of data divided by ten blocks

for the last tick, divide by at most the number of blocks we actually have data for and not by block_resolution.

kristovatlas commented 8 years ago

I thought I had already addressed this in db.Database.get_blame_stats_for_block_span_and_resolution, so it's possible I'm not correctly assessing the root cause.