+ Reply to Thread
Results 1 to 4 of 4

Count repetitions of occurences of value

  1. #1
    Registered User
    Join Date
    08-07-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    2

    Count repetitions of occurences of value

    Hi all,

    I've got quite a challenge for the smart guys amongst us.

    count repetitions.jpg

    Attached pic shows a simplified example of what I am trying to do.

    I've got a large number of rows, in which a's and b's are repeated randomly. Now I am looking for a formula resulting in the max number of consecutive a's (meaning repetitions), without interruption by b's and the same for the b's.

    I also want to find the average repetitions of each value.

    An extra challenge is that the last group of values should be ignored, because incomplete (the columns are dates and still counting).

    Give it your best shot and thx in advance!

    Gert

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Count repetitions of occurences of value

    Hi and welcome to the forum

    Please do not upload a picture of your file...rather, upload a sample of your workbook, showing what data you are working with, a few samples of your expected outcome is (manually entered is ok) and how you arrived at that. (exclude sensitive info). Pictures are pretty much impossible to edit, and no-one wants to re-type your data for you
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    08-07-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    2

    Re: Count repetitions of occurences of value

    Thx FDibbins, will do!

    Here is the table (remember, it's a very simple example, my sheet is quite big)

    A B C D E F G H I
    a a a b a a b b b
    a a a a b b a a a
    a b b b b b b b a

    Expected answers:

    J K L M
    Max repetitions a Max repetitions b Average repetitions a Average repetitions b
    3 1 2.5 1
    4 2 4 2
    1 7 1 7

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,926

    Re: Count repetitions of occurences of value

    thats hardly "upload a sample of your workbook", but hopefully some-one will be able to work with it

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. How to count the occurences
    By Elainefish in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 05-16-2013, 04:00 AM
  2. Formula to count occurences
    By ssmith0011984 in forum Excel General
    Replies: 3
    Last Post: 07-09-2010, 04:46 PM
  3. compare and count value repetitions
    By ElmerS in forum Excel General
    Replies: 6
    Last Post: 02-10-2010, 05:30 PM
  4. Count the number of occurences of a value
    By therealjag in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 01-19-2010, 06:25 AM
  5. [SOLVED] Count occurences
    By AvalancheMike in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-24-2005, 08:06 PM

Tags for this Thread

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