how to display stat. significance (*) in the chart

Yishih

New Member
Joined
Oct 16, 2002
Messages
2
Is there a way to automatically display asterisk(s) in a bar chart (similar to displaying data labels) without adding a text box of "*" to the chart?
 

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number
Hi Yishih,

What do you mean by "automatically?" Yes, you can assign the label to a bar in VBA, if that is what you are asking. For example, the code

With activesheet.ChartObjects(1).Chart.SeriesCollection(1).points(4)
.hasdatalabel = true
.datalabel.text = "*"
End With

will turn on the datalabel for point 4 in series 1 of chart object 1 on the active worksheet, and set it to "*".

I hope this helps.

Damon
 
Upvote 0
Thanks, Damon, for responding to my question. Suppose I have two sets of values:

Group1Rte Group2Rte PValue
10% 50% .001
30% 32% .85
70% 90% .04

After making a bar chart of the two sets, I'd like to display an "*" on any of the three Group2's bars if the p values are less than .05. In the above example, "*" will be displaed on top of two of the three bars (groups).

I'd like to make this happen automatically in an Excel workbook with multipe worksheets - each has a similar layout. I use SAS macros and DDE to output data to Excel in iterations.

Yishih
 
Upvote 0

Forum statistics

Threads
1,214,858
Messages
6,121,960
Members
449,057
Latest member
FreeCricketId

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top