Thanks for your comments.
Here is how you should use annotations
function drawVisualization() {
var data = new google.visualization.DataTable();
data.addColumn('date', 'Date');
data.addColumn('number', 'Sold Pencils');
data.addColumn('string', 'title');
data.addColumn('string', 'text');
data.addRows(2);
data.setValue(0, 0, new Date(2008, 1 ,1));
data.setValue(0, 1, 30000);
data.setValue(0, 2, 'aaaa')
data.setValue(0, 3, 'bbbb')
data.setValue(1, 0, new Date(2008, 1 ,2));
data.setValue(1, 1, 14045, 'aaaa');
data.setValue(1, 2, 'cccc')
data.setValue(1, 3, 'dddd')
var annotatedtimeline = new google.visualization.AnnotatedTimeLine(
document.getElementById('visualization'));
annotatedtimeline.draw(data, {'displayAnnotations': true});
}
As for the custom properties of any data table entity (row, column or cell).
They are for your own use, you can tag any entity with additional
information and later use it.
The chart will not use the custom property you set unless declared
otherwise.
ChartMan
On Thu, Dec 16, 2010 at 4:49 PM, James Dooley <[email protected]> wrote:
> Ok i figured it out... although I am still puzzled by the way google
> finance has done their stuff...
>
> To actually add annotations at the bottom, you actually need to add
> three columns.. one with a number, then you have to add 2 more text
> columns after... 0 doesn't work..
> but 0.01 does but his looks rather strange so I am still not
> satisfied..
>
>
>
> On Dec 16, 3:13 pm, James Dooley <[email protected]> wrote:
> > I have made some progress here.
> >
> > It appears as if that description Annotation title and description is
> > still incorrect though.
> >
> > Here is what I had to do.
> >
> > For the annotations title, add a new text column.
> > For the annotations description, add a new text column.
> >
> > No problem. Although this is not very sexy and as claimed in the doc,
> > I can live with that.
> >
> > Now, how do make the annotations appear at the bottom ?
> > Athttp://www.google.com/finance?q=NASDAQ:MSFT
> > they are the bottom.
> >
> > Also, how do I add dividens ?
> >
> > Also, is the google finance stuff not really using the same tools we
> > do ? Are they using the same annotated JS lib?
> > Should we be able to do the same stuff they've done ? How do I create
> > dividends then... I somehow doubt that we are..
> >
> > Cheers, James
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Visualization API" group.
> To post to this group, send email to
> [email protected].
> To unsubscribe from this group, send email to
> [email protected]<google-visualization-api%[email protected]>
> .
> For more options, visit this group at
> http://groups.google.com/group/google-visualization-api?hl=en.
>
>
--
You received this message because you are subscribed to the Google Groups
"Google Visualization API" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-visualization-api?hl=en.