Results 1 to 2 of 2
  1. #1
    4 Star Lounger
    Join Date
    Jan 2001
    Thanked 1 Time in 1 Post

    Proportionate circles (Excel xp)

    I have 3 circles. #1 represents 608. #2 represents 417. and #3 represents 117. I made a bubble chart and then traced the circles with the drawing tool but wanted to know if there is a better way to draw the circles more accurately. I need to color them and put them in powerpoint and couldn't cut/paste the circles out of the bubble chart. Thank you for the help.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Thanked 31 Times in 31 Posts

    Re: Proportionate circles (Excel xp)

    Here is a macro to use as a starting point; you'll have to fine-tune it yourself.

    Sub DrawCircles(oRange As Range, Factor As Single)
    Const Const1 = 100
    Dim i As Integer
    Dim r As Single
    Dim oSheet As Worksheet
    Set oSheet = ActiveSheet
    For i = 1 To oRange.Cells.Count
    r = Sqr(oRange.Cells(i)) * Factor
    oSheet.Shapes.AddShape msoShapeOval, Const1, i * Const1, r, r
    Next i
    Set oSheet = Nothing
    End Sub

    The arguments to this macro are
    (1) a range containing the values, for example Range("A1:A3"), or Selection
    (2) a sizing factor, try 5 or 10. The area of the circles is proportional to the values, use the sizing factor to tweak the size.

    Example of use:

    DrawCircles Range("A1:A3"), 5


    DrawCircles Selection, 8

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts