sparklines

97 views
Skip to first unread message

danibto

unread,
Dec 7, 2007, 5:31:31 AM12/7/07
to Google Chart API
i'm building sparlines for an app, and i found 2 problems to do it:

- how can i hide the axis lines?

- i want to put a shape marker on end point, but the chart hasn't
enough margins and the marker appears broken, how can i set the chart
margins

thanks in advance

Uwe Maurer

unread,
Dec 9, 2007, 10:06:33 PM12/9/07
to Google Chart API
Hi !

On Dec 7, 11:31 am, danibto <dani...@gmail.com> wrote:
> i'm building sparlines for an app, and i found 2 problems to do it:
>
> - how can i hide the axis lines?

We will add a new line chart type for sparklines that has the axis
lines disabled.

Until then you can use this:

http://chart.apis.google.com/chart?cht=lc&chs=100x50&chd=s:ABcd34GFh&chco=1E90FF&chxt=x%2Cy&chxs=0%2C000000%2C10%2C0%2C_%7C1%2C000000%2C10%2C0%2C_&chxl=0:%7C%7C1:%7C

It adds and x and y axis and then uses the chxs parameter to turn off
the axis lines. The last parameter of chxs is '_' which means no lines
and no ticks. (also 't' for ticks, and 'l' for lines and 'lt' for both
works, we will add this to the documentation)

> - i want to put a shape marker on end point, but the chart hasn't
> enough margins and the marker appears broken, how can i set the chart
> margins

We will add a parameter to control the margin.

Thanks,
Uwe

riezebosch

unread,
Jan 24, 2008, 5:39:02 AM1/24/08
to Google Chart API

riezebosch

unread,
Jan 24, 2008, 7:51:52 AM1/24/08
to Google Chart API
This is because you set the font size to 10. When lowering this to 1
it works quite well. This also the minimum because when setting to 0
the complete picture is not visible.

Adam Greene

unread,
Jan 24, 2008, 6:20:39 PM1/24/08
to Google Chart API
Hi Uwe,

very nice!!

I'm not sure if this a bug or not, but take a look at this chart and
the red dot at the end of the line:
http://chart.apis.google.com/chart?chco=76A4FB&cht=lfi&chf=bg,s,ffffff&chs=350x125&chm=r,E5ECF9,0,0.19,0.38%7Co,AA1100,0,29,5&chd=e:jxbeSHakjBZNXsVISkYrdgiafPb7QmpgMiYw6GcEh9jFiMhNcBfjoJVSfehl

The red dot is cut off. Now if I have a y-axis defined on the right
side or specify a legend, there is enough padding to show the red dot
in its full glory.

Would you mind letting me know if you would like me to file a bug or
feature ticket?

thanks!
Adam



On Dec 9 2007, 7:06 pm, Uwe Maurer <uwe.mau...@google.com> wrote:
> Hi !
>
> On Dec 7, 11:31 am, danibto <dani...@gmail.com> wrote:
>
> > i'm building sparlines for an app, and i found 2 problems to do it:
>
> > - how can i hide the axis lines?
>
> We will add a new line chart type forsparklinesthat has the axis
> lines disabled.
>
> Until then you can use this:
>
> http://chart.apis.google.com/chart?cht=lc&chs=100x50&chd=s:ABcd34GFh&...
Reply all
Reply to author
Forward
0 new messages