ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Charts and Charting in Excel (https://www.excelbanter.com/charts-charting-excel/)
-   -   How do I shade a region between two selected points on the x axis? (https://www.excelbanter.com/charts-charting-excel/82334-how-do-i-shade-region-between-two-selected-points-x-axis.html)

cmc14

How do I shade a region between two selected points on the x axis?
 
In a line graph of monthly unemployment rates over many years, economists
like to shade a region between 2 selected months (x axis) in order to denote
a recsession. How can this be done in an Excel chart?



vandenberg p

How do I shade a region between two selected points on the x axis?
 
Hello:

I am sure that someone very cleaver will tell you there is an automated
way to do this. But given the irregular nature of the data, and not
frequently the easiest way to do it would be to dislay the drawing
toolbar. Now choose the rectangle shape and draw the area you want high
lighted. Once you have the area you want covered, right click the rectangle
and choose format autoshape and set the transparency to about 50%, this
depends on the color you choose and whether you will be printing or only
using a display. I find sometimes it is best to have no line or times
a line works well. You can do other areas the same way. You can vary
the colors and transparency setting to highlight what you want.

If you click the graph before you the box it wil stay the graph, if you
draw the box with clicking the graph the box is independent of the
graph. I frequently like this better because you have greater control.
If you want them to stay together just shift click them and choose
group from the draw menu.

Pieter Vandenberg


cmc14 wrote:
: In a line graph of monthly unemployment rates over many years, economists
: like to shade a region between 2 selected months (x axis) in order to denote
: a recsession. How can this be done in an Excel chart?



Andy Pope

How do I shade a region between two selected points on the xaxis?
 
Hi,

If you x axis is a category axis then the simple way is to add another
series and plot it as a column chart. You will need to set the maximum
value of the Y axis and use the same value for your column series data.
Place the value against each data point you want shading. Format the
column series to have a Gap Width of zero, this option is on the Series
Option of the format dialog.

If the dates are being plotted as true dates then you could use a second
data series plotted as an area chart. This will require some addition
date points in order to make the end of the plot vertical.

Cheers
Andy

cmc14 wrote:
In a line graph of monthly unemployment rates over many years, economists
like to shade a region between 2 selected months (x axis) in order to denote
a recsession. How can this be done in an Excel chart?



--

Andy Pope, Microsoft MVP - Excel
http://www.andypope.info


All times are GMT +1. The time now is 04:21 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com