Hi asgallan, Sorry for the delayed reply. I think I may have had a slightly misunderstanding of the continuous elements of the graphs but it makes sense now. I used your tweak and that's given me an option to work with.
Thanks for your help. On Wednesday, 17 July 2013 19:24:04 UTC+1, asgallant wrote: > > Your vAxis baseline is working just fine, but with those chart values and > a baseline of 1, it is indistinguishable from a baseline of 0. If you set > the baseline at 100, you can see it working: > http://jsfiddle.net/asgallant/BGCtG/1/ > > Your hAxis, however, is not continuous, as your years are being entered as > strings. If you input them as numbers, the axis becomes continuous, but > with a baseline value of 1, the chart probably doesn't look like what you > want: http://jsfiddle.net/asgallant/BGCtG/2/. The solution is to remove > the baseline value (unless you explicitly want to override it): > http://jsfiddle.net/asgallant/BGCtG/3/ > > On Wednesday, July 17, 2013 11:44:14 AM UTC-4, Russell Burgoyne wrote: >> >> Hi Jeremy, thanks for getting back. >> >> I've been testing on the example chart code to make sure nothing I had >> done was conflicting with it. Below is the example with some basic >> parameters for baseline and baselineColor I've added in which is giving a >> red line on the vAxis but nothing on the hAxis: >> >> google.load("visualization", "1", {packages:["corechart"]}); >> google.setOnLoadCallback(drawChart); >> function drawChart() { >> var data = google.visualization.arrayToDataTable([ >> ['Year', 'Sales', 'Expenses'], >> ['2004', 1000, 400], >> ['2005', 1170, 460], >> ['2006', 660, 1120], >> ['2007', 1030, 540] >> ]); >> >> var options = { >> title: 'Company Performance', >> vAxis: {baseline: 1, baselineColor: 'red'}, >> hAxis: {baseline: 1, baselineColor: 'blue'}, >> }; >> >> var chart = new >> google.visualization.LineChart(document.getElementById('chart_div')); >> chart.draw(data, options); >> } >> >> Any help would be appreciated. >> >> Thanks. >> >> On Wednesday, 17 July 2013 15:54:17 UTC+1, Jeremy Faller wrote: >>> >>> Any chance we can get some code you've tried? >>> >>> On Wednesday, July 17, 2013 9:54:45 AM UTC-4, Russell Burgoyne wrote: >>>> >>>> Hi all, >>>> >>>> Having a slight problem with getting the baseline to appear on the y >>>> axis in a line chart. >>>> >>>> Not hugely experienced in using google charts but from what I've read >>>> and tried I can't see anything else I can do. I'm using a continuous chart >>>> so all unsupported discrete issues shouldn't be present. I've tried adding >>>> baseline parameters (e.g. baseline: '10', baselineColor: 'red') but this >>>> doesn't fix it. The closest example I can find of anything close is the >>>> use >>>> of chxt for image charts, which would be perfect but is now depreciated >>>> (and I'm not using an image chart). Are there any other alternatives for >>>> this or is there any way to get that y axis line to show up? >>>> >>>> Thanks in advance. >>>> >>> -- 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.
