+ Reply to Thread
Results 1 to 7 of 7

Transform table with duplicates into table without duplicates and corresponding averages

  1. #1
    Registered User
    Join Date
    01-23-2013
    Location
    Leuven, Belgium
    MS-Off Ver
    Excel 2007
    Posts
    3

    Transform table with duplicates into table without duplicates and corresponding averages

    Hi all!

    I guess my question is easier to understand when looking at the attached Excel file.

    The easiest way to formulate my question is: how to get from the table on the left to the table on the right using Excel formulas and functions? ;-)
    But more in detail...

    - I have 4 features (column E) which all have a different data point (column D). I would like to make the average of the differences for all the features separately (column J), but as you notice, the number of datapoints is different for each feature.

    - I would also like to mention in 2 separate columns the start (column H) and end (column I) corresponding to the first and last position (column C) of each feature.

    Is it possible to do this in Excel in a more automated way since I have 1000s of these features...?

    It's a complicated question, I am sorry, but every bit of information is highly appreciated!
    Attached Files Attached Files
    Last edited by u0046619; 01-25-2013 at 11:19 AM.

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,733

    Re: Transform table with duplicates into table without duplicates and corresponding averag

    You can use this formula in J2:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    then copy down to J5.

    Hope this helps.

    Pete

  3. #3
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Transform table with duplicates into table without duplicates and corresponding averag

    A pivot table also will work (if the position values always move from low to high)

    In the row fields, Chromasome and Feature
    In Data Minimum of Position, Maximum of Position and Average of Difference

    Format the Row fields to tabular. See example
    Attached Files Attached Files
    ChemistB
    My 2?

    substitute commas with semi-colons if your region settings requires
    Don't forget to mark threads as "Solved" (Edit First post>Advanced>Change Prefix)
    If I helped, Don't forget to add to my reputation (click on the little star at bottom of this post)

    Forum Rules: How to use code tags, mark a thread solved, and keep yourself out of trouble

  4. #4
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,733

    Re: Transform table with duplicates into table without duplicates and corresponding averag

    The attached example generates the summary table automatically. Let me know if you need an explanation of the formulae (dinner's ready now).

    Hope this helps.

    Pete
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    01-23-2013
    Location
    Leuven, Belgium
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Transform table with duplicates into table without duplicates and corresponding averag

    I will have a look at it tomorrow, diner is also ready now ;-)
    But I would like to thank you already for your help!
    I'll let you know as soon as I had a closer look.
    Thx!

  6. #6
    Registered User
    Join Date
    01-23-2013
    Location
    Leuven, Belgium
    MS-Off Ver
    Excel 2007
    Posts
    3

    Re: Transform table with duplicates into table without duplicates and corresponding averag

    Hi Pete_UK and ChemistB!
    Thanks a lot both of you for your solution of the problem; it really helped me a lot!
    I just generated my first Pivot Table ever, great! :-)

  7. #7
    Forum Guru
    Join Date
    08-05-2004
    Location
    NJ
    MS-Off Ver
    365
    Posts
    13,582

    Re: Transform table with duplicates into table without duplicates and corresponding averag

    Glad to help. Thanks for the star click.

+ 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