+ Reply to Thread
Results 1 to 8 of 8

sum frequency based on certain dates

  1. #1
    Registered User
    Join Date
    12-19-2007
    Location
    Venezuela
    Posts
    4

    Question sum frequency based on certain dates

    Good day, I have the following data in a worksheet:

    2 1 1-Apr-14
    2 2 1-Apr-14
    3 1 31-Mar-14
    3 2 31-Mar-14
    3 3 31-Mar-14
    3 4 31-Mar-14
    3 5 31-Mar-14
    3 6 31-Mar-14
    4 1 21-Dec-14
    5 1 2-Feb-14
    6 1 15-Jan-14
    6 2 15-Jan-14
    7 1 3-Apr-14
    8 1 1-Mar-14
    9 1 1-Jan-14

    I want to count unique numbers in 1st column on a certain month of 3rd column.

    Thanks in advance.
    Lio.

  2. #2
    Registered User
    Join Date
    03-30-2014
    Location
    Suzhou,China
    MS-Off Ver
    Excel 2003
    Posts
    41

    Re: sum frequency based on certain dates

    Assuming your data is in [A1:C15] and the certain month is 6, you could try this array formula:

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


    Enter this array formula with CTRL+SHIFT+ENTER
    Welcome to China,Welcome to Suzhou...And,我是来学英文的。

  3. #3
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: sum frequency based on certain dates

    Try this...

    Data Range
    A
    B
    C
    D
    E
    F
    1
    2
    1
    1-Apr-14
    Jan
    2
    2
    2
    2
    1-Apr-14
    Feb
    1
    3
    3
    1
    31-Mar-14
    Mar
    2
    4
    3
    2
    31-Mar-14
    Apr
    2
    5
    3
    3
    31-Mar-14
    May
    0
    6
    3
    4
    31-Mar-14
    Jun
    0
    7
    3
    5
    31-Mar-14
    Jul
    0
    8
    3
    6
    31-Mar-14
    Aug
    0
    9
    4
    1
    21-Dec-14
    Sep
    0
    10
    5
    1
    2-Feb-14
    Oct
    0
    11
    6
    1
    15-Jan-14
    Nov
    0
    12
    6
    2
    15-Jan-14
    Dec
    1
    13
    7
    1
    3-Apr-14
    14
    8
    1
    1-Mar-14
    15
    9
    1
    1-Jan-14
    16
    ------
    ------
    ------
    ------
    ------
    ------


    This array formula** entered in F1 and copied down:

    =SUM(IF(FREQUENCY(IF(TEXT(C$1:C$15,"mmm")=E1,A$1:A$15),A$1:A$15),1))

    ** array formulas need to be entered using the key
    combination of CTRL,SHIFT,ENTER (not just ENTER).
    Hold down both the CTRL key and the SHIFT key
    then hit ENTER.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  4. #4
    Registered User
    Join Date
    12-19-2007
    Location
    Venezuela
    Posts
    4

    Re: sum frequency based on certain dates

    Quote Originally Posted by wcymiss View Post
    Assuming your data is in [A1:C15] and the certain month is 6, you could try this array formula:

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


    Enter this array formula with CTRL+SHIFT+ENTER
    Good day wcymiss, thanks for you reply, i'm getting 0 as result for this array formula.

    Lio.

  5. #5
    Registered User
    Join Date
    12-19-2007
    Location
    Venezuela
    Posts
    4

    Re: sum frequency based on certain dates

    Quote Originally Posted by Tony Valko View Post
    Try this...

    Data Range
    A
    B
    C
    D
    E
    F
    1
    2
    1
    1-Apr-14
    Jan
    2
    2
    2
    2
    1-Apr-14
    Feb
    1
    3
    3
    1
    31-Mar-14
    Mar
    2
    4
    3
    2
    31-Mar-14
    Apr
    2
    5
    3
    3
    31-Mar-14
    May
    0
    6
    3
    4
    31-Mar-14
    Jun
    0
    7
    3
    5
    31-Mar-14
    Jul
    0
    8
    3
    6
    31-Mar-14
    Aug
    0
    9
    4
    1
    21-Dec-14
    Sep
    0
    10
    5
    1
    2-Feb-14
    Oct
    0
    11
    6
    1
    15-Jan-14
    Nov
    0
    12
    6
    2
    15-Jan-14
    Dec
    1
    13
    7
    1
    3-Apr-14
    14
    8
    1
    1-Mar-14
    15
    9
    1
    1-Jan-14
    16
    ------
    ------
    ------
    ------
    ------
    ------


    This array formula** entered in F1 and copied down:

    =SUM(IF(FREQUENCY(IF(TEXT(C$1:C$15,"mmm")=E1,A$1:A$15),A$1:A$15),1))

    ** array formulas need to be entered using the key
    combination of CTRL,SHIFT,ENTER (not just ENTER).
    Hold down both the CTRL key and the SHIFT key
    then hit ENTER.
    Thanks for your reply Tony Valko, how to do the same without the helper column? i need to do this count to fill a pre-formated dashboard data that is in other worksheet on the same workbook.

    Lio.

  6. #6
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: sum frequency based on certain dates

    What helper column? Do you mean column E with the month names? If you don't have month names how else would you do this?

    Show us what results you expect.

  7. #7
    Registered User
    Join Date
    12-19-2007
    Location
    Venezuela
    Posts
    4

    Re: sum frequency based on certain dates

    Quote Originally Posted by Tony Valko View Post
    What helper column? Do you mean column E with the month names? If you don't have month names how else would you do this?

    Show us what results you expect.
    Thanks for your reply Tony,

    I tweaked your solution to make it work, here's how it looks like:
    Please Login or Register  to view this content.
    Thanks again for your help,
    Lio

  8. #8
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: sum frequency based on certain dates

    Good deal. Thanks for the feedback!

+ 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. ActiveX DatePicker: Specify Certain Available Dates/Frequency by Listbox Choice
    By excelforumkeys in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 12-31-2013, 07:11 PM
  2. Frequency of Dates
    By sophia.b.ali in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 11-13-2012, 05:08 PM
  3. Frequency of dates chart
    By Badger123 in forum Excel Charting & Pivots
    Replies: 5
    Last Post: 04-15-2008, 11:19 AM
  4. [SOLVED] FREQUENCY and dates
    By [email protected] in forum Excel General
    Replies: 4
    Last Post: 03-16-2006, 08:35 AM
  5. Ranking based on frequency
    By mac_see in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-01-2006, 12:55 PM

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