A pivot table might do what you are asking for. Select your data then click on Data, Pivot Table and work through the wizard.