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

Last tick (grid column) extended. #4576

Closed
MichalMisiaszek opened this issue Jul 27, 2017 · 3 comments
Closed

Last tick (grid column) extended. #4576

MichalMisiaszek opened this issue Jul 27, 2017 · 3 comments

Comments

@MichalMisiaszek
Copy link

Expected Behavior

I am charting 1440 values with 1440 chart labels (minutes in 24 hours) in range (0-23).
I have checked that I have exactly 60 labels with 23 (minutes in hour) same as for every other hour.
The grid should be evenly spread.

Current Behavior

The last grid column is stretched and do not keep scale with others.

Possible Solution

None.

Steps to Reproduce (for bugs)

  1. Define data with 1440 data points.
  2. Define chart labels from 0 to 23, each value 60 times.
  3. xAxes: [{
    ticks: {
    stepSize: 1,
    maxTicksLimit: 26,
    suggestedMax: 24
    },
    scaleLabel : {
    display: true,
    fontColor: '#000000',
    labelString: 'Time UTC (hours)'
    }
    }],
  4. Draw.

Context

The chart looks bad :(.

Environment

@etimberg
Copy link
Member

@MichalMisiaszek based on your settings it looks like you wanted to use a numerical x axis. However, that hasn't been set so it would default to a category axis. You need to add type: 'linear' to the x axis config if you want a linear scale.

Alternatively, you can look at some of the new time scale settings that are in master. See #4507, #4568, and #4556 for details

@etimberg
Copy link
Member

Closing as out of date

@BriFuture
Copy link

Hi, When I set type: 'linear' ,X axis seems right, but no data displayed on canvas, but data has been stored in myChart instance.
Oh, I found the solution on #4687

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

No branches or pull requests

3 participants