Skip to content

[Bug] YAxis type 'log' with logBase: 2 working wierd #18858

Open
@winkyBrain

Description

Version

5.4.2

Link to Minimal Reproduction

https://echarts.apache.org/examples/en/editor.html?c=line-stack&code=PYBwLglsB2AEC8sDeAoWtJgDYFMBcya6GOAHmAQOQDKYAhgMYDWOAJrADITQ6VEC-AGiJhgwLJBAFUxDACcIAc0U45VOqQgBnPuiFFcK6K2lF0rOvQIBtSgFEAtnQhZKg2JQCq0KHACCrDrulABqEKw4wLABQR4AIhByOAxgbh7UOHRyDAAWsHbQity8ALoCwuiKCiaEsrgAZhQeAMwApG5msAqKOU2UACztFcQARsBgog5UbR2yDDD03Bx0IzhYBGByAK445SJiWGOkprL1mWBbSSeysFp0AG44floAkk4q0vydX3rDpH6aLTXdBgACeIHwHgYlhwimAclBs1GwC2xiyoIA4nQpLB6nQsFocMNzJY6DZKABZGBpSgAFR2NIA6mwabSclsaQAxBQ06iWXmoyhlX5EUEA7TAjDgyGULDARRI9ByxQAITohIIACZhvp0ISFDggbBrJ0ZDdoHQHDLHM5XMTiGCIVQsMVFcQLFZjQBGTUABncXua2tgXt9XoDzX67gAnP7YJrmnHNaHhcRdcQzbILVaqN5fNFAm6QdLna77STPdZNX6AwAOYNe6Ph-OR9ya2MB9zNFPfe2Z4jZmVhCJRGJFqVOjwunjjj1k70AViTQbbYYDC6jIY7sGaifc_R7snT6H76EHVASSRS48dMunvHLsDnNiDcd3wcTzd3m-a293b79VMRVkU9YHPdJMmyPICiKGdH1vUs4M6Ct52ses42jFdYFjZtMM3H1t0DPcQ1rX1fSA2AflgMp-AAbiAA

Steps to Reproduce

  1. Set yAxis.type to 'log'
  2. set yAxis.logBase: 2;

Current Behavior

yAxis labels starts from 1, then 1024 and 1 048 576. That's it, only 3 labels on Y axis. but biggest value in series is 1800

Expected Behavior

I definitely don't need 1 048 576 as max label if max value is 1800. As logarithm based of 2 max label should be 2048. But if you change logBase to any other number(3, 4, etc.) - everything works fine, for example with same series and logBase: 4 max label is 4094

Environment

- OS:
- Browser:
- Framework:

Any additional comments?

No response

Metadata

Assignees

No one assigned

    Labels

    enThis issue is in Englishnot-a-bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions