c3js / c3js/c3

Bar width ratio and tick values/count

Open
#1,368 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
9.3k
Forks
1.4k
Avg merge
6d 16h
Merged PRs (30d)
1

Description

The bar width ratio does not calculate correctly when the number of ticks is different from the number of columns in a bar chart because of using the x tick values or x tick count options.

Here is an example: http://jsfiddle.net/L7od79g3/1/

The bar width ratio seems to be based on the distance between the ticks. I feel that it would be better if the bar width ratio was relative to the width between the columns instead.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the bar chart from the linked JSFiddle with different x tick values and x tick count options. Trace how the chart calculates bar width relative to tick spacing and column spacing; done means bar widths remain correct when the number of ticks differs from the number of columns.

Written by the indexing model from the issue text.

Assessment

Tech stack
d3, javascript
Domain
data-visualization
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.