+ Reply to Thread
Results 1 to 3 of 3

Summing Data based on Its Category

  1. #1
    sip8316
    Guest

    Summing Data based on Its Category

    I have a spread sheet that has data on buldings set up in such a way that the
    rows are different room types and the columns are Floor Type and Sq.
    Footage. At the bottom of the sheet I have a row that gives total square
    footage for each floor type of all the rooms combined.

    Right now I am using the Sum() function but I have to go through and
    individually select sq footages for the respective floor type. For example
    if 3 rooms have a cement floor I look down the sq footage column and sum the
    ones that have "cement" in the floor type column, and same with capret, etc.
    respectively.

    Is there a way to use an if statement or anything else so that excel
    automatically searches for a certain floor type and only adds the square
    footage for those and puts that value in a cell.

    Help if you can.

  2. #2
    Jay
    Guest

    Re: Summing Data based on Its Category

    > I have a spread sheet that has data on buldings set up in such a way
    > that the rows are different room types and the columns are Floor Type
    > and Sq. Footage. At the bottom of the sheet I have a row that gives
    > total square footage for each floor type of all the rooms combined.
    > ...
    > Is there a way to use an if statement or anything else so that excel
    > automatically searches for a certain floor type and only adds the
    > square footage for those and puts that value in a cell.


    One way is to use SUMIF.

    Below is an example as a CSV file that can be loaded into Excel.

    (Hopefully, plain ascii text like this doesn't violate the "attachments"
    taboo.)

    ----------------- cut here --------------
    cement,12444
    wood,1144
    cement,4563
    carpet,4444
    cement,1258
    wood,2467
    wood,14244
    wood,6465
    carpet,12345


    Totals,
    cement,"=SUMIF(A$1:A$11,A13,B$1:B$11)"
    wood,"=SUMIF(A$1:A$11,A14,B$1:B$11)"
    carpet,"=SUMIF(A$1:A$11,A15,B$1:B$11)"

  3. #3
    Biff
    Guest

    Re: Summing Data based on Its Category

    Hi!

    Floor type range = C2:C100
    Sq. Footage range = D2:D100

    =SUMIF(C2:C100,"cement",D2:D100)

    Better if you use a cell to hold the criteria:

    A1 = cement

    =SUMIF(C2:C100,A1,D2:D100)

    Biff

    "sip8316" <[email protected]> wrote in message
    news:[email protected]...
    >I have a spread sheet that has data on buldings set up in such a way that
    >the
    > rows are different room types and the columns are Floor Type and Sq.
    > Footage. At the bottom of the sheet I have a row that gives total square
    > footage for each floor type of all the rooms combined.
    >
    > Right now I am using the Sum() function but I have to go through and
    > individually select sq footages for the respective floor type. For
    > example
    > if 3 rooms have a cement floor I look down the sq footage column and sum
    > the
    > ones that have "cement" in the floor type column, and same with capret,
    > etc.
    > respectively.
    >
    > Is there a way to use an if statement or anything else so that excel
    > automatically searches for a certain floor type and only adds the square
    > footage for those and puts that value in a cell.
    >
    > Help if you can.




+ 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