+ Reply to Thread
Results 1 to 6 of 6

Need Chart's Line to Skip Zero Values

  1. #1
    Registered User
    Join Date
    05-06-2008
    Posts
    55

    Need Chart's Line to Skip Zero Values

    Hi all,

    [Please see the attachment for description below.]
    I’m trying to create a graph which tracks our production. I have a USER SHEET which employees use to enter their daily production and which can be filtered to show only the month the company is currently working on. Because the filter would remove cells needed for each months chart, each chart works from another unfiltered set of fields on a separate sheet called REPORTS SHEET which replicates the data from the USER SHEET. There are some days which are blank and which I need to be able to see in the database, but which I don’t want to show in the chart. (An example of this is the 4th of October.) Currently the values for the replicated blank cells are showing as zero on my chart because of the function located in that cell.

    Does anyone know how to get the chart’s line to skip over the blank values so there will be just a smooth transition from one cell containing a value to the other? I have attached a spreadsheet incase some brave soul has any ideas for me.

    Thank you so much for the help!
    Attached Files Attached Files
    Last edited by ComcoDG; 10-14-2008 at 11:28 AM.

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,612
    Right click your charts, select Chart options, Axes and finally Category instead of Automatic. The bar chart looks neater for your data.
    Last edited by protonLeah; 10-14-2008 at 12:31 AM.
    Ben Van Johnson

  3. #3
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436
    Change your formula on the Reporting sheet.

    B2: =IF('User Sheet'!C2<>"",'User Sheet'!C2,NA())

    Using "" instead of NA() will result in the zero as any text in the chart data series is treated as zero.
    The NA() will stop the data marker from being plotted. The line however will be plotted between valided data points.
    Cheers
    Andy
    www.andypope.info

  4. #4
    Registered User
    Join Date
    05-06-2008
    Posts
    55
    Thanks for the responses and for the ideas.

    The NA() text works for a single cell, but unfortunately it returns error for all days not yet completed. This is a problem when calculating the average production, or if the first cell in the chart’s source data is left blank by the user. For example, in the attached you will see that the month of September works fine when the users doesn’t leave blank cells, but October runs into errors for blank cells as does November. I’ve look through the varying results and can’t seem to see why some are returning the error.

    It's so close!
    Attached Files Attached Files

  5. #5
    Forum Guru Andy Pope's Avatar
    Join Date
    05-10-2004
    Location
    Essex, UK
    MS-Off Ver
    O365
    Posts
    20,436
    you need to adapt your formula to take into account the NA's

    D2: =SUM(IF(ISNUMBER($B$2:$B$26),$B$2:$B$26))/COUNT(IF(ISNUMBER($B$2:$B$26),$B$2:$B$26))

    This is an Array formula so commit with CTRL+SHIFT+ENTER

  6. #6
    Registered User
    Join Date
    05-06-2008
    Posts
    55

    Thumbs up

    Andy,

    Your function works brilliantly! It even solves another annoying item which I had just made my peace with. Namely, the graph listed zeros for all days currently missing. Now only days are charted which have actually been completed.

    I am not familiar with Array formulas and have some reading ahead of me.

    Thank you for your help and for broadening my horizons!

    David

+ 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. Exporting one column to text file
    By Brelin in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 08-21-2008, 12:29 AM
  2. Calculate series of numbers with different values
    By caldera55 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 05-18-2008, 06:08 PM
  3. Removing $0 Values from Charts
    By starbwoy in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 04-07-2008, 01:48 PM
  4. automatically update charts
    By slimjen in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 09-04-2007, 06:25 PM
  5. Charts not representing values
    By eiolon in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 08-09-2007, 04:56 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