6
$\begingroup$

Trying to make a waterfall bar chart. I got this far:

yData = {10, 7, 4, 2}
upFromX = Accumulate[yData] - yData
xyDataWithUplift = 
 Table[{Style[upFromX[[i]], White], yData[[i]]}, {i, 1, Length[yData]}]
BarChart[xyDataWithUplift, ChartLayout -> "Stacked"]

which is getting there but I can't figure out how to make the bottom rectangle's edge blank. Tried EdgeForm[] and EdgeForm[White] but no luck.

$\endgroup$
10
$\begingroup$

How about this?

yData = {10, 7, 4, 2, -5, -2, 3};
    BarChart[yData, ChartLayout -> "Stepped"]

enter image description here

$\endgroup$
  • $\begingroup$ thx - that's so obvious it never occurred to me... now that I see it, that's exactly how a 'stepped' layout should behave1 $\endgroup$ – Joe May 6 '18 at 4:26
0
$\begingroup$

I expected ChartStyle -> {{None, Automatic}} to work but it still had the edge.

ChartStyle -> {{Directive[EdgeForm[], FaceForm[]], Automatic}} on the other hand does remove the edge.

$\endgroup$

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.