leeoniya / leeoniya/uPlot

Small numbers don't render properly on axis

Open
#775 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
10.5k
Forks
463
PR merge metrics
No merged PRs in 30d

Description

I have numbers in the picometer range. The axis around 10**-3 starts to render incorrectly. Around 10**-10, the lines start to render incorrectly.

For now, multiplying all y-numbers by 10**9 makes things work.

Any advice on working w/ small numbers?

My axis settings just look like this:

axes: [
      {
        scale: "x",
      },
      {
        scale: "y",
      },
    ],

Bad y-axis labels for 10**-3
image


Bad lines around 10**-11

image

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the issue with picometer-scale values and the shown x/y axis settings, checking the labels near 10**-3 and line rendering near 10**-10 to 10**-11. Compare the result with values multiplied by 10**9, and consider the issue done when small values produce correctly rendered labels and lines without rescaling the data.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
data-visualization
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.