Creating a Separate Chart for Each Row of Data

  • Thread starter Thread starter HobieJuan
  • Start date Start date
H

HobieJuan

I need to create 150 similar charts for 150 separate rows of data contained
in an Excel 2003 spreadsheet. I am not an accomplished Macro author. Any
bright ideas out there?
 
Need a bit more info. Can you post a sample of the data you have including
column headers etc?
What sort of chart do you want?
Do you need to be able to view all or multiple charts simultaneously. Under
some circumstances using AutoFilter allows you to create just one chart and
it becomes dynamic based on the AutoFilter setting.
If AutoFilter option used, do you have a column with unique values or titles
that would allow selection of a specific line of data. Alternatively would it
be out of the question to add a column and simply number from 1 to 150 and
use that to select the individual rows.
It is fairly simple then to write code to set the Autofilter and print each
chart if required.
 
OssieMac,
Thanks for the reply! What I am after is a very simple side by side bar
chart that shows a single bar for an individual employees % rating next to a
bar for the global employee average. I am not sure how to post an example,
but the spread sheet that I am pulling data from is also very simple. It has
a column of employee names followed by a column for their % values on
corresponding rows. The global average data is calculated as the last row or
data.
Thanks again,
HobieJuan
 
Does your data look something like the following table? (I have used a random
string generator for the Emp names.)

Emp Name Emp % Global Ave
Efccxp 80% 82%
Hrlsovd 84% 82%
Yczxyo 85% 82%
Yfzxcv 80% 82%
Hpfxdvu 89% 82%
Hhagans 85% 82%
Ochpees 74% 82%
Tihcctab 77% 82%
Wjkegwku 71% 82%
Djwumo 94% 82%

The formula for the Global average is
=AVERAGE(B:B)

Note that using the column references in the formula in lieu of actual cell
start and finish references allows you to add rows and still copy the same
formula down to the new rows.

If the data looks like the above then you can select the data and create a
column chart. Initially you will see all of the employees charted on a single
chart. (If the chart creates itself on the same worksheet then select the
chart then cut and paste it to a worksheet of its own because it will not
work well with AutoFilter on the same worksheet as the data.)

Apply AutoFilter to the data and select an individual employees name and the
chart will be dynamic and only display that employees percentage and the
global percentage.

If your data does not look like the above and for whatever reason it is not
possible to rearrange it that way then copy a sample of your data and post it
here. (Just use AAA, BBB, CCC etc for employee names to maintain privacy
provisions.)
 
OssieMac,

That worked like a charm. Thanks a million!!!!!!!!!! You just saved me
from many hours of tedium.

HobieJuan
 
Back
Top