Grouped Vertical Bar Chart not working with particular series of data
See original GitHub issueI’m submitting a … (check one with “x”)
[ ] bug report
Current behavior Bar Vertical 2d Graph ( Grouped Vertical Bar Chart ) is not populating
Expected behavior Bar Vertical 2d Graph ( Grouped Vertical Bar Chart ) should be populated
Reproduction of the problem Bar Vertical 2d Graph ( Grouped Vertical Bar Chart ) is not populating with the following data
[{"name":"201701","series":[{"name":"Post-Control","value":13740},{"name":"Post-Test","value":12348},{"name":"Pre-Control","value":13598},{"name":"Pre-Test","value":12334}]},{"name":"201702","series":[{"name":"Post-Control","value":15558},{"name":"Post-Test","value":9298},{"name":"Pre-Control","value":15409},{"name":"Pre-Test","value":9278}]},{"name":"201703","series":[{"name":"Post-Control","value":14365},{"name":"Post-Test","value":11337},{"name":"Pre-Control","value":14193},{"name":"Pre-Test","value":11320}]},{"name":"201704","series":[{"name":"Post-Control","value":12889},{"name":"Post-Test","value":13535},{"name":"Pre-Control","value":12701},{"name":"Pre-Test","value":13507}]},{"name":"201705","series":[{"name":"Post-Control","value":12277},{"name":"Post-Test","value":13809},{"name":"Pre-Control","value":12072},{"name":"Pre-Test","value":13779}]},{"name":"201706","series":[{"name":"Post-Control","value":16076},{"name":"Post-Test","value":9332},{"name":"Pre-Control","value":15821},{"name":"Pre-Test","value":9301}]},{"name":"201707","series":[{"name":"Post-Control","value":17734},{"name":"Post-Test","value":7578},{"name":"Pre-Control","value":17453},{"name":"Pre-Test","value":7558}]},{"name":"201708","series":[{"name":"Post-Control","value":19068},{"name":"Post-Test","value":5618},{"name":"Pre-Control","value":18807},{"name":"Pre-Test","value":5601}]},{"name":"201709","series":[{"name":"Post-Control","value":12675},{"name":"Post-Test","value":10356},{"name":"Pre-Control","value":12494},{"name":"Pre-Test","value":10324}]},{"name":"201710","series":[{"name":"Post-Control","value":16788},{"name":"Post-Test","value":6516},{"name":"Pre-Control","value":16550},{"name":"Pre-Test","value":6497}]},{"name":"201711","series":[{"name":"Post-Control","value":17328},{"name":"Post-Test","value":5819},{"name":"Pre-Control","value":17119},{"name":"Pre-Test","value":5806}]},{"name":"201712","series":[{"name":"Post-Control","value":18003},{"name":"Post-Test","value":5674},{"name":"Pre-Control","value":17802},{"name":"Pre-Test","value":5665}]},{"name":"201713","series":[{"name":"Post-Control","value":19696},{"name":"Post-Test","value":3438},{"name":"Pre-Control","value":19535},{"name":"Pre-Test","value":3436}]}];
It was working in 3.0.4.
Reproduced this issue on official site -> https://swimlane.gitbooks.io/ngx-charts/content/charts/bar-vertical-2d.html by changing data.
Please tell us about your environment: MAC - 10.12.4 , npm - 3.10.10
-
ngx-charts version: 5.1.2
-
Angular version: 4.0.3
-
Language: [all | TypeScript 2.2.2 | ES6/7 | ES5]
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (1 by maintainers)
Top GitHub Comments
Seems the default value of groupPadding (16px) and barPadding (8px) was the culprit for the given view of 400 * 220.
Reducing the groupPadding and barPadding solved the issue.
Closing the issue
Yes, solved it pretty much for me. I was wondering why the lines were so thin, but then I took your suggestion and started with 0 for both parameters, and locked to the ones I was comfortable with. Cheers!