Solved

Pivot Table with merged cells

Posted on 2011-09-06
8
10,401 Views
Last Modified: 2012-05-12
EE Professionals,

I have a simple pivot table that I have attached where I have a set of merged cells in the columns and then two variables under each merged cell.  I'm trying to use a pivot table to begin to do some analysis and have found that I may not be able to use merged cells in a pivot table.

I'd appreciate it if someone would take a look at this sample and give me some ideas on how to attack the problem of using a pivot table for this type of simple analysis.

Thank you in advance.

B.
0
Comment
Question by:Bright01
  • 4
  • 3
8 Comments
 

Author Comment

by:Bright01
ID: 36491177
Sorry.... Here's the file.
Pivot-Table-Analysis-v1.xlsm
0
 
LVL 7

Expert Comment

by:BusyMama
ID: 36491261
Yes, I believe you would have to rearrange your data table, suggest as such:

Name  Area1Current  Area1Future  Area2Current  Area2Future

etc.

Then you should be able to create a pivot table.
0
 
LVL 50

Expert Comment

by:teylyn
ID: 36492349
Hello Bright,

You're right, you cannot use merged cells in the column headers for a pivot table. The column headers must be in one row only and each column must be a distinct name.

In fact, using merged cells leads to all kinds of problems and should be avoided. Use "Center across selection" in the Alignment tab of the formatting dialog instead if you want to center text across several cells.

Looking at your table, this looks like a typical RESULT for a pivot table, with a data source of just 4 columns. See attached

cheers, teylyn
Pivot-Table-Analysis-v1.xlsm
0
 

Author Comment

by:Bright01
ID: 36492595
Teylyn,

Woah... I didn't know...this is way beyond Graphics.  How do you get from a Pivot Table to the A,B,C,D output you have in your example?  I really like what you have done with the merged cells..... I can aggrigate the merged cells so to see the totals.  How did you get the output to show up based on the Pivot table?

I need some explanation.

Much thanks,

B.
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 50

Expert Comment

by:teylyn
ID: 36492667
Hi, it's the other way round. Normally one starts off with a flat data table like the one in columns A to D, then you build the pivot table from that data.

But if you have a table laid out like the pivot table, there are ways to create a flat data table from that. I did it manually for the data sample, but for bigger datasets, I'd use a different process.

Is that what you need to do? I'm not sure what exactly you are after, you know, the three old questions: What/where is the data input? What is the desired output? What are the processing rules?

cheers, teylyn
0
 

Author Comment

by:Bright01
ID: 36492720
Fair enough.  

1.) I have data input from 177 sources that are providing "partially" inputted data to 12 categories.  This includes 67 participants who are inputting partial data (i.e. the 177 sources since multiple participants are inputting to multiple categories but no one is inputting to all categories).  From this data, I'm going to "gleem" insights...thus the pivot table request.

2.) The input will be a table with both actual and null values since many of the participants will provide only partial data. What I have learned so far is that Pivot Tables won't act on merged cells.

3.) The desired output will be averages of the data that is provided.  Thus the use for the pivot table.

4.) The process rules are take the data from the categories which are represented by the columns and be able to aggrigate the data and do some analysis that includes summary by category, averages by category based on values/input and other elements that I can gleem from a pivot table analysis.

Sorry to give you all that..... It's way more then expected.  I don't expect you to advise on all those elements but thought I'd give you the big picture.  Any insight would be appreciated as I structure the datafile and use Excel's Pivot Table capability.

This type of question for EE I try to break down to small compoents and work from there.  The first part was what I sent initially which was a very small sample table.

I hope this helps.  Please advise.

B.

0
 
LVL 50

Accepted Solution

by:
teylyn earned 500 total points
ID: 36493266
Starting from the spreadsheet you posted above. Given this is the data source, you can quickly turn that into a suitable source for a pivot table.

Unmerge the merged cells, in the resulting empty cells (every other cell in the title) put a formula to refer to the text to the immediate left, in your example, M6 receives the formula

=L6

Copy that formula to O6 and Q6.

Now insert a row above Name1.

In cell L8 (the new, empty row) enter the formula

=L6&L7

copy across. In K8 enter the title "Name".

Now you have a flat table that can be used as a source for a pivot analysis. Whether or not the data is suitable for the kind of analysis you want to undertake, I can't say. Select K8:Q11 and insert a pivot table. Play around with it and see.

I'm pretty sure you'll not get anything meaningful out of that, but, again, I don't know what your analysis goal is.

The data source I attached in my first comment allows to slice and dice data by Area, current/future state, and Name. If that is what you want to do, then you will need a data source with just the four columns I outlined, instead of the data source with multiple columns per area.

If your data comes from different sources, then you really have two issues:

- how to flatten data that is stored in a report format
- how to build a meaningful pivot report from the flattened data

cheers, teylyn

0
 

Author Closing Comment

by:Bright01
ID: 36494761
Very good commentary and clear directions.  I've gotten the table flattened and am now playing with different input/analysis.

Appreciate the effort and the education!

B.
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

What is a Form List Box? (skip if you know this) The forms List Box is the alternative to the ActiveX list box. If you are using excel 2007, you first make sure you have a developer tab (click the Orb)->"Excel Options"->Popular->"Show Developer tab…
How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
The viewer will learn how to create a normally distributed random variable in Excel, use a normal distribution to simulate the return on an investment over a period of years, Create a Monte Carlo simulation using a normal random variable, and calcul…
This Micro Tutorial will demonstrate on a Mac how to change the sort order for chart legend values and decrpyt the intimidating chart menu.

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now