Hi, I assume you're talking about the Image Charts (which are now deprecated), and not the newer Visualization API, which is for web sites (it is JavaScript-based), since app inventor only makes Android apps. In order to construct something like that, you should follow the instructions here<https://developers.google.com/chart/image/docs/gallery/line_charts>. >From what you specified, it seems like you want the 'lxy' chart type, since you probably want to see and specify both the x and y data. For example, take the following chart URL: https://chart.googleapis.com/chart?cht=lxy&chs=200x125&chd=t:10,20,40,80,90,95,99|20,30,40,50,60,70,80|-1|5,10,22,35,85&chco=3072F3,ff0000,00aaaa&chls=2,4,1&chm=s,000000,0,-1,5|s,000000,1,-1,5&chdl=Ponies|Unicorns&chdlp=t We can split it up into its individual parameters, to make it a bit easier to read: cht=lxy chs=200x125 chd=t:10,20,40,80,90,95,99|20,30,40,50,60,70,80|-1|5,10,22,35,85 chls=2,4,1 chm=s,000000,0,-1,5|s,000000,1,-1,5 chdl=Ponies|Unicorns chdlp=t And then cross-check these with the documentation to figure out what each of them means. cht=lxy : This is the chart type that allows us to specify the X and Y values. chs=200x125 : This is the chart size chd=t:10,20,40,80,90,95,99|20,30,40,50,60,70,80|-1|5,10,22,35,85 : This is the chart data. As outlined in the page I linked to, this will parse to a chart with two lines, which will have the following values: 10, 20 20, 30 40, 40 80, 50 90, 60 95, 70 99, 80
And the second line says -1|5,10,22,35,85. This wouldn't make sense, as there aren't enough X values for the Y values, but the documentation says that the value of '-1' will make the chart space evenly, so you only have to specify the Y values there. chls=2,4,1 : These are the line styles. chm=s,000000,0,-1,5|s,000000,1,-1,5 : These are the line fills. chdl=Ponies|Unicorns : This is the chart legend chdlp=t : And this is the position for the chart legend (it puts it on the top). You can find the documentation for the shared options here<https://developers.google.com/chart/image/docs/chart_params>. I hope this helps! - Sergey On Sat, Dec 15, 2012 at 11:55 AM, Sjoerd Jansma <[email protected]> wrote: > Hey guys. > > I've got a formula with a model which I wanna have in an app. I saw a > beautiful tutorial about how to get a chart from Google API into an app > made by app inventor. > Only thing is, I don't actually know how to make the url for the formula > in Google API. I also want to adjust variables in the formula. Is that > possible with the combination of App Inventor and Google API? > Second question: could anyone help me with that? > I attached the model as an image. > > Thanks > Sjoerd > > *Sorry for my bad English.* > > -- > You received this message because you are subscribed to the Google Groups > "Google Visualization API" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/google-visualization-api/-/kAI27HQ5w14J. > 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. > -- 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.
