New in Wolfram
Mathematica
8: Statistical Visualization
◄
previous

next
►
Graphics & Visualization
Compare University Salaries
Compare the distribution of salaries for several departments at a university, labeled with department size.
In[1]:=
X
salaries = ExampleData[{"Statistics", "UniversitySalaries"}, "DataElements"]; depts = {"Mathematics", "History", "English", "Chemistry", "Law", "Physics", "Statistics"}; salaries = Table[Cases[salaries, {d, _, salary_, "A"} :> salary], {d, depts}];
In[2]:=
X
DistributionChart[salaries, ChartLabels > Placed[{depts, Length /@ salaries}, {Axis, Center}], ChartStyle > 54, BarOrigin > Left, AspectRatio > 1, LabelStyle > {FontSize > 16}, ImageSize > 575, BaseStyle > {FontFamily > "Helvetica"}, LabelStyle > Bold]
Out[2]=