+ Reply to Thread
Results 1 to 5 of 5

Weighted Average with multiple variables

  1. #1
    Registered User
    Join Date
    02-26-2011
    Location
    tennessee
    MS-Off Ver
    Excel 2003
    Posts
    2

    Weighted Average with multiple variables

    Hey all,

    So I am trying to calculate avg. cost per customer contacted by mail. The stats look like this:

    126 2895 $9.04 1
    104 724 $2.72 2
    164 685 $1.65 5
    a b c d

    A=number of customers in segment
    B=size of segment
    C=Cost to reach actual customer in segment(at .55 cost per mail piece)
    D=Number of pieces mailed to segment

    So getting C for each segment is easy its just =((B1)*(.55))/R1

    but figuring out the weighted average for C of the whole mail plan when each D is different is incredibly frustrating.

    Any ideas?

  2. #2
    Valued Forum Contributor
    Join Date
    02-12-2011
    Location
    The Netherlands
    MS-Off Ver
    365
    Posts
    818

    Re: Weighted Average with multiple variables

    Array formula
    Please Login or Register  to view this content.
    After copy Ctrl+Shift+Enter

    Or:
    Please Login or Register  to view this content.
    just Enter.
    Last edited by HSV; 02-26-2011 at 08:36 PM. Reason: Formula in Englisch version not Dutch
    Kind regards, Harry.

  3. #3
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: Weighted Average with multiple variables

    I'm not sure what this formula represents

    =((B1)*(.55))/R1

    wouldn't you multiply by the number sent to each segment in D1? What's in R1 you don't mention that?

    Assuming you want a weighted cost for C given numbers in D try

    =SUMPRODUCT(C2:C10,D2:D10)/SUM(D2:D10)
    Audere est facere

  4. #4
    Registered User
    Join Date
    02-26-2011
    Location
    tennessee
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: Weighted Average with multiple variables

    Sorry, R1=A1

    So the formula "=SUMPRODUCT(C2:C10,D2:D10)/SUM(D2:D10)" and all D=1 gives me what seems like a reasonable number(1.39)....BUT.....the formula "=((SUM(B1:B3))*(.55))/SUM(A1:A3)" gives a different one(1.22) even though it should be the same as long as all D's=1.

    What am I missing?
    Last edited by bigtoad; 02-26-2011 at 08:56 PM. Reason: THANKS!!!!

  5. #5
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: Weighted Average with multiple variables

    If every entry in column D is 1 then the weighted average is the same as a straight average of column C so this would give the same result

    =AVERAGE(C2:C10)

    You can't get the equivalent of that by using

    =SUM(B2:B10)*0.55/SUM(A2:A10)

    you'd have to use an "array formula" to get the equivalent, i.e.

    =AVERAGE(B2:B10*0.55/A2:A10)

    confirmed with CTRL+SHIFT+ENTER

    See the attached where if column D are all 1s the 3 different formulas in G2:G4 will all give the same results. G3 and G4 will always be the same but G2 will differ if D2:D10 has different results. Press F9 to generate some different random values
    Attached Files Attached Files

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1