We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
I have a line chart with data
[{y: "2012", a: 4.5},{y: "2011", a: 3.66}, {y: "2010", a: 4.2}, {y: "2009", a: 4.1}, {y: "2008", a: 3.8}, {y: "2007", a: 4.4},{y: "2006", a: 3.2}]
and options
xkey: "y", ykeys: ["a"], labels: ["Series A"], hideHover: true, ymax: 5, ymin: 0
When I render the graph, I have no 2 on my Y-axis and the grid line is missing
I've tried with the graph at different sizes and the problem persists.
If I change the ymax to 6 I lose both number 2 and 4.
max 5 / min 1 works but max 6 / min 1 loses number 3.
I've tried with the released version 0.3.3 and the version from Github.
The text was updated successfully, but these errors were encountered:
I think the error is in Morris.Grid at line 182
@yInterval = (@ymax - @ymin) / (@options.numLines - 1) if @yInterval > 0 and @yInterval < 1 @precision = -Math.floor(Math.log(@yInterval) / Math.log(10)) else @precision = 0
setting the numLines options to 6 manually worked for me.
I've see the default for numLines is 5, that seems quite arbitrary and causes significant problems in this case!
Sorry, something went wrong.
There's definitely scope to improve the Y-axis labelling code. Right now it's very naive, and I think I can do better.
Watch this space.
Closing this as a dupe of #162. It's not exactly the same problem, but we should fix both at the same time.
No branches or pull requests
I have a line chart with data
[{y: "2012", a: 4.5},{y: "2011", a: 3.66}, {y: "2010", a: 4.2}, {y: "2009", a: 4.1}, {y: "2008", a: 3.8}, {y: "2007", a: 4.4},{y: "2006", a: 3.2}]
and options
xkey: "y",
ykeys: ["a"],
labels: ["Series A"],
hideHover: true,
ymax: 5,
ymin: 0
When I render the graph, I have no 2 on my Y-axis and the grid line is missing
I've tried with the graph at different sizes and the problem persists.
If I change the ymax to 6 I lose both number 2 and 4.
max 5 / min 1 works but max 6 / min 1 loses number 3.
I've tried with the released version 0.3.3 and the version from Github.
The text was updated successfully, but these errors were encountered: