+ Reply to Thread
Results 1 to 9 of 9

Sample variance formula that can be dragged down

  1. #1
    Registered User
    Join Date
    03-19-2010
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2010, 2007,2002
    Posts
    60

    Sample variance formula that can be dragged down

    In the attached sheet i need a formula for the sample variance on the first row that correspond to all the "A" in a row and the same for all the "B" in the row. The challenge is all the A's and B's change in every row but the numbers at the top stay the same. I need this formula to be able to drag down. I have tried If statements inside of var.s but this doesnt work because the value if false is 0 and we dont want that in the same variance. to clear up any confusion what i want to do is find some way to say if the first cell in a row is A include the number at the top of the column in the variance calculation, if its not A then do not include it in the calculation.
    Attached Files Attached Files
    Last edited by rmb623; 05-30-2011 at 01:46 AM.

  2. #2
    Forum Guru
    Join Date
    03-12-2010
    Location
    Canada
    MS-Off Ver
    2010 and 2013
    Posts
    4,418

    Re: Sample variance formula that can be dragged down

    Hi,

    This may be obvious to others, but I truly cannot understand what you are doing. Do the A's and B's in the real worksheet represent numbers? I'm just not following your example.

    abousetta

  3. #3
    Registered User
    Join Date
    03-19-2010
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2010, 2007,2002
    Posts
    60

    Re: Sample variance formula that can be dragged down

    Quote Originally Posted by abousetta View Post
    Hi,

    This may be obvious to others, but I truly cannot understand what you are doing. Do the A's and B's in the real worksheet represent numbers? I'm just not following your example.

    abousetta
    so what i am doing is i want to take the variance of the numbers in row 1. however i am dividing the variance into two parts. for every row there are different A's and different B's. I want to take the variance of the numbers in the same column as the A's and the variance of the numbers in the same column as the B's. let me know if its still confusing

  4. #4
    Forum Guru
    Join Date
    03-12-2010
    Location
    Canada
    MS-Off Ver
    2010 and 2013
    Posts
    4,418

    Re: Sample variance formula that can be dragged down

    I still don't undestand. I honestly don't see a pattern here. How can you drag the formula and ask Excel to recognize a pattern if it changes fom row to row randomly. Now if you mean that the data will be somewhere else and then the A's and B's are labels for the actual data then this is another story, but what is the pattern. I am sorry but I still don't understand what you are trying to accomplish.

    abousetta

  5. #5
    Registered User
    Join Date
    03-19-2010
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2010, 2007,2002
    Posts
    60

    Re: Sample variance formula that can be dragged down

    Quote Originally Posted by abousetta View Post
    I still don't undestand. I honestly don't see a pattern here. How can you drag the formula and ask Excel to recognize a pattern if it changes fom row to row randomly. Now if you mean that the data will be somewhere else and then the A's and B's are labels for the actual data then this is another story, but what is the pattern. I am sorry but I still don't understand what you are trying to accomplish.

    abousetta
    values in the far right column are examples of what i want tocalculate. what i want to do is find some way to say if the first cell in a row is A include the number at the top of the column in the variance calculation, if its not A then do not include it in the calculation.

  6. #6
    Forum Guru
    Join Date
    03-12-2010
    Location
    Canada
    MS-Off Ver
    2010 and 2013
    Posts
    4,418

    Re: Sample variance formula that can be dragged down

    OK. Now I can see a pattern. Sorry about not understanding what you were after. Let's see if I can find a solution before anyone else.

    abousetta

  7. #7
    Forum Guru
    Join Date
    03-12-2010
    Location
    Canada
    MS-Off Ver
    2010 and 2013
    Posts
    4,418

    Re: Sample variance formula that can be dragged down

    Would something like this work for you:

    Please Login or Register  to view this content.
    abousetta

  8. #8
    Registered User
    Join Date
    03-19-2010
    Location
    Houston, Texas
    MS-Off Ver
    Excel 2010, 2007,2002
    Posts
    60

    Re: Sample variance formula that can be dragged down

    I would need the formula to extend to G so from your example it would be extended to
    Please Login or Register  to view this content.
    However this returns a #VALUE! error....i think because we get some of the " " in the computation and I do not believe the var.s formula recognizes that.

  9. #9
    Forum Guru
    Join Date
    03-12-2010
    Location
    Canada
    MS-Off Ver
    2010 and 2013
    Posts
    4,418

    Re: Sample variance formula that can be dragged down

    I apologize. I admit that my formula was not correct in all circumstances after further testing. Even so, this should work (attachment)

    Please Login or Register  to view this content.
    Good luck.

    abousetta
    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