Skip to content
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

Bar graph using Log scale sometimes truncates values #334

Closed
mreid-moz opened this issue Feb 9, 2018 · 4 comments
Closed

Bar graph using Log scale sometimes truncates values #334

mreid-moz opened this issue Feb 9, 2018 · 4 comments
Milestone

Comments

@mreid-moz
Copy link

mreid-moz commented Feb 9, 2018

Issue Summary

When using a categorical x-axis and a logarithmic scale y-axis, sometimes a bad value is selected as the max Y and results in data being truncated.

Steps to Reproduce

Using a prestodb datasource, enter the following query (or click here):

with sample as (
    select 'a' as x, -1 as foo union
    select 'b' as x, 0 as foo union
    select 'c' as x, 1 as foo union
    select 'd' as x, 10 as foo union
    select 'e' as x, 100 as foo union
    select 'f' as x, 1000 as foo union
    select 'g' as x, 10000000000 as foo union
    select 'h' as x, 1000 as foo union
    select 'i' as x, 1000 as foo union
    select 'j' as x, 1000 as foo union
    select 'k' as x, 1000 as foo union
    select 'l' as x, 1000 as foo union
    select 'm' as x, 1000 as foo union
    select 'n' as x, 1000 as foo union
    select 'o' as x, 1000 as foo
)
select * from sample

Then create a chart with the x field on the x axis, the foo field on the y axis, configure the x axis as categorical, and set the y axis to logarithmic scale.

I would expect the Y axis to scale up to 10,000,000,000 (where x = 'g'), but instead the Y axis scales only to 10,000 and truncates the bar for g:
screen shot 2018-02-09 at 2 19 34 pm

Technical details:

  • Redash Version:
  • Browser/OS: Firefox Nightly 60.0a1 (2018-02-09) (64-bit) / macOS High Sierra
  • How did you install Redash: sql.telemetry.mozilla.org
@mreid-moz
Copy link
Author

As a workaround, you can manually enter a Max Value for the Y-axis.

@rafrombrc rafrombrc added this to the 14 milestone Feb 21, 2018
@rafrombrc rafrombrc modified the milestones: 14, 13 Feb 28, 2018
@washort
Copy link

washort commented Mar 13, 2018

Looks like this is a plotly version issue. Upgrading my local deployment to the version used upstream fixed the problem for me.

@washort
Copy link

washort commented Mar 14, 2018

This works on stage, which uses the up-to-date plotly version.

@washort washort closed this as completed Mar 14, 2018
@washort washort removed the ready label Mar 14, 2018
@madalincm
Copy link

Verified as fixed in FF59(Win7) in stmo-stage
Postfix screencast:
334
Marking bug as verified fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants