Hi,

>From your code snippet, we can't tell what kind of chart your are drawing,
what options you have tried.

Starting with the Playground AreaChart, I replaced the drawVisualization
with:

      function drawVisualization() {
        // Some raw data (not necessarily accurate)
      var data = new google.visualization.arrayToDataTable([['Year','jan',
'feb','mar','apr','may','Jun','other'],
                                    ['2010',1,0,0,0,2,0,0],
                                    ['2011',1,4,0,0,0,0,0],
                                    ['2012',8469,20,8485,649,476,0,982],
                                    ['2013',2618,0,2617,69,0,246,276]]);

        // Create and draw the visualization.
        var ac = new google.visualization.ColumnChart(document.
getElementById('visualization'));
        ac.draw(data, {
          title : 'Monthly Coffee Production',
          vAxis: {title: "Cups", logScale: true},
          hAxis: {title: "Month", gridlines: { count: -1} }
        });
      }

And got this output:

http://savedbythegoog.appspot.com/?id=db72832439488418a1a836097d0940ca8b08117e

It sounds like you are using side-by-side columns, and you don't want the
empty spaces for the series that have zero values.  It wouldn't help to
replace the zeros with nulls either, since the column chart always reserves
space for series.  I can see that it might be a useful option, however,
which we might consider adding.   This is analogous to stacking the columns
(add isStacked: true to the options) where the zero values take up no space
in the column.

dan



On Wed, Jul 31, 2013 at 8:53 AM, chartuser <[email protected]> wrote:

> Hi all,
>
> kindly let me know how to hide a column in without empty space in combo
> chart.
>
>  var data = new 
> google.visualization.arrayToDataTable([['Year','jan','feb','mar','apr','may','Jun','other'],
>
>                                                     [2010,1,0,0,0,2,0,0],
>
>                                                     [2011,1,4,0,0,0,0,0],
>
>                                                     
> [2012,8469,20,8485,649,476,0,982],
>
>                                                             
> [2013,2618,0,2617,69,0,246,276]])
>
>
> Consider the sample array, i need to hide the chart if the value is zero. 
> currently there is an empty space when the countis zero. so for the first 
> array only the two columns must be displayed.
>
>
> let me know how to achieve this
>
>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to
> [email protected].
> Visit this group at
> http://groups.google.com/group/google-visualization-api.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2>  -
978-394-1058
[email protected] <[email protected]>   562D 5CC, Cambridge MA
[email protected] <[email protected]> 9 Juniper Ridge
Road, Acton MA

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to