[Help] Creating a bar chart with one sided rounded rectangle #1201
Answered
by
mbostock
dennismphil
asked this question in
Q&A
-
Happy New Year! I need a bit of help in creating the chart shown below. The columns need to be rounded on the top end only and the y-axis dates need to be formatted so that the y-axis formatted date labels are aligned with the center of the bars. How would you go about implementing this? Notebook |
Beta Was this translation helpful? Give feedback.
Answered by
mbostock
Dec 30, 2022
Replies: 1 comment 2 replies
-
Here is my suggestion using the rx option, and then “faking it” by using a negative insetBottom and clip. Plot.rectY(data, {x: "Date", y: "Count", interval: d3.utcDay, rx: 6, insetBottom: -3, clip: "frame"}) https://observablehq.com/d/022b0876b936b4cb Edit (July 2024): This is now supported in Plot as of #2099. |
Beta Was this translation helpful? Give feedback.
2 replies
Answer selected by
dennismphil
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Here is my suggestion using the rx option, and then “faking it” by using a negative insetBottom and clip.
https://observablehq.com/d/022b0876b936b4cb
Edit (July 2024): This is now supported in Plot as of #2099.