+ Reply to Thread
Results 1 to 8 of 8

Frequency Array Excluding Zeros

  1. #1
    Registered User
    Join Date
    11-20-2011
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2003
    Posts
    4

    Frequency Array Excluding Zeros

    Hi Everyone, first time posting here.

    So, I have a set of numbers ranging between 0.15 and 1.5, in 0.01 increments. What I'm trying to do is count the number of instances each number appears in the set (ex - how many times is 0.76 listed).

    I've tried creating a frequency array using my data set and another column with the upper and lower banding values (so from .15 to 1.5 in 0.01 increments). The problem with this approach is that I'm getting a lot of zeros (ex. .36 might not appear in my data set, so the frequency array returns a value of zero for .36). These zeros are throwing off my analysis.

    Is there any way to exclude/omit frequencies of zero from my analysis? Should I even be using a frequency array to solve this problem?

    Thanks!
    B

  2. #2
    Forum Expert darkyam's Avatar
    Join Date
    03-05-2008
    Location
    Houston, TX
    MS-Off Ver
    2013
    Posts
    2,191

    Re: Frequency Array Excluding Zeros

    Sounds like you could use countif, as in =COUNTIF(A$1:A$1000,C1), where C1 has your table. To not include 0s, you can use, =IF(COUNTIF(A$1:A$1000,C1),COUNTIF(A$1:A$1000,C1),""). That will make the cells text, which will keep them from being counted in formulas like Average.
    Life is about perseverance. Remember: today's mighty oak tree is just yesterday's nut that held its ground.

    If you like a post, please rate it with the scales icon (top right).
    If you feel really indebted, please consider a donation to charity, such as Feed the Children or Habitat for Humanity.

  3. #3
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Frequency Array Excluding Zeros

    Welcome to the forum.

    One way:

    Please Login or Register  to view this content.
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    11-20-2011
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Frequency Array Excluding Zeros

    Thanks for the suggestions, they make sense. Unfortunately, I'm having trouble getting the COUNTIF to work - it always returns a zero. I know this probably is a really basic issue, I just haven't used the function before.

    Any help will be appreciated,
    Thanks!
    B

  5. #5
    Forum Expert ConneXionLost's Avatar
    Join Date
    03-11-2009
    Location
    Victoria, Canada
    MS-Off Ver
    2010
    Posts
    2,952

    Re: Frequency Array Excluding Zeros

    To best describe or illustrate your problem you would be better off attaching a dummy workbook, the workbook should contain the same structure and some dummy data of the same type as the type you have in your real workbook - so, if a cell contains numbers & letters in this format abc-123 then that should be reflected in the dummy workbook. Don't upload a picture when you have a workbook. None of us is inclined to recreate your data. Upload the workbook and manually add an 'after' situation so that we can see what you expect. In addition clearly explain how you get the results.

    To attach a file to your post, you need to be using the main 'New Post' or 'New Thread' page and not 'Quick Reply'.
    To use the main 'New Post' page, click the 'Post Reply' button in the relevant thread.

    On this page, below the message box, you will find a button labelled 'Manage Attachments'.
    Clicking this button will open a new window for uploading attachments.

    You can upload an attachment either from your computer or from another URL by using the appropriate box on this page.
    Alternatively you can click the Attachment Icon to open this page.

    To upload a file from your computer, click the 'Browse' button and locate the file.

    To upload a file from another URL, enter the full URL for the file in the second box on this page.
    Once you have completed one of the boxes, click 'Upload'.

    Once the upload is completed the file name will appear below the input boxes in this window.
    You can then close the window to return to the new post screen.
    Would you like to say thanks? Please click the: " Add Reputation" button, on the grey bar below the post.

  6. #6
    Registered User
    Join Date
    11-20-2011
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Frequency Array Excluding Zeros

    Hi, Again, thanks for the advice. I've uploaded a document to illustrate my problem.
    B
    Attached Files Attached Files

  7. #7
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678

    Re: Frequency Array Excluding Zeros

    Your data isn't as you described it.

    Please Login or Register  to view this content.

  8. #8
    Registered User
    Join Date
    11-20-2011
    Location
    Chicago, IL
    MS-Off Ver
    Excel 2003
    Posts
    4

    Re: Frequency Array Excluding Zeros

    I see now that my original description of the data was inaccurate - I believe my mistake was that the Excel cells were formatted to show only 2 decimal places, so I assumed that my bins only had to have 2 decimal places.

    Sorry about the confusion,
    B

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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