Hi All,

I have googled and tried finding if someone has ever tried producing
(Grouped + Stacked) Barplot. I couldn't find one.

My data needs to be reshaped, but once it is done it would be something like
this:

Factor1    Factor2    Factor3    Value
A    X    P    10
A    X    Q    20
A    Y    P    20
A    Y    Q    5
A    Z    P    20
A    Z    Q    10
B    X    P    20
B    X    Q    10
B    Y    P    30
B    Y    Q    50
B    Z    P    10
B    Z    Q    20

There are three categorical variables (Factor1, Factor2, and Factor3 having
2,3, and 2 levels resp.). I'm trying to plot "Factor1" on x axis -- each
level of this factor should have three (grouped) bars (one for each level of
Factor2). Which will further be stacked by each level of Factor3.

Can anyone guide me please, thanks,
~Xin

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to