-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add minexponent
attribute to control usage of SI prefixes in axis ticks
#5121
Conversation
Works just like `SI`, except it uses prefixes for kilo- and milli-.
Hide SI prefix for 10^n if |n| <= minexponent
@ignamv could you please investigate why the test image fails for these mocks?
|
Sure, I'll see if I can run the image tests locally. |
Is it possible that the failure is not related to my changes? I see the exact same failing tests in the master branch: |
Yes it is possible. But strangely today I was not able to rerun the workflow of this branch on the CircleCI! |
Hi, I was wondering if there's something left to do on my end. |
@ignamv minexponent: opts.minexponent |
There are still a few comments on this PR which are not resolved. |
Nicely done. |
Thanks! But what about the failing tests? |
For some strange reason, I was not able to re-run your workplace on CI. Also CI was very unstable during the past day. |
Resolves #5111
Presently, SI prefixes are not used for powers of 10 smaller than 3 (no prefixes for 10^-3, 10^-2, ..., 10^3).
The new
minexponent
attribute defaults to3
, which matches the current behavior. By setting it to 0, one can force the usage of SI prefixes for all powers of 10 (including 1m, 10m, ..., 1k). By setting it to a large value, one can disable SI prefixes up to a certain value (using plain numbers instead).@plotly/plotly_js