Solved

Excel 2007:  Stop line chart data labels from overlapping

Posted on 2013-05-23
4
1,586 Views
Last Modified: 2013-06-19
Hello Experts,

I have several charts that I fix the label formats so they don't overlap.  Just requires a slight move nothing big.  I was wondering if there are any macros out there that would do this for me?

Thanks!!

Using Excel 2007
example.docx
0
Comment
Question by:Maliki Hassani
4 Comments
 
LVL 80

Accepted Solution

by:
byundt earned 500 total points
ID: 39192762
I'm not aware of any existing code to optimize label placement.

Were I to write a macro to optimize label positioning, my first attempt would be using the Solver add-in to minimize the square of the distance between the label and the point, subject to the constraint that labels shouldn't overlap. There might be an additional constraint that the data point should lie outside the label. Solver would find it easiest to solve the problem if there were a calculation of the % of overlap for each label.

If you just have a few charts, it would be far easier to use manual positioning. Excel 2007 can position the labels for each series on top of, above, below, right or left of the points. In addition, you can drag an individual label to a new position.

For the sample chart in the Word document, I'd use label below the points for the bottom series, and above the points for the top two series. I'd also suggest increasing the height of the y-axis, such as be changing the minimum scale value to 150. Label tweaking shouldn't take more than a minute or two per chart.

For best presentation, I'd eliminate both the markers and data labels. If the reader needs the data, there should be a separate table listing it. The point of the chart is to communicate the trends, and the data labels and markers get in the way of that communication.
0
 

Author Comment

by:Maliki Hassani
ID: 39192777
That sounds good!  I did find a macro that reposition the labels on google but it didn't work.  I think if I set the labels like you stated it could work.  I will leave the thread open for now and close tomorrow afternoon.

Thank you!!
0
 
LVL 45

Expert Comment

by:Martin Liss
ID: 39258773
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
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

When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
The viewer will learn how to use the =DISCRINV command to create a discrete random variable, use this command to model a set of probabilities and outcomes in a Monte Carlo simulation, and learn how to find the standard deviation of a set of probabil…
This Micro Tutorial demonstrates how to create Excel charts: column, area, line, bar, and scatter charts. Formatting tips are provided as well.

707 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

15 Experts available now in Live!

Get 1:1 Help Now