I have a PHP script that processes data from a MySQL database. It basically is a series of amplitude values for a range of frequencies. The output winds up in 2 arrays, one holds the frequency (1, 1.5, 2, 2.5 ... 30) and the other holds the amplitude values (for example 2.5, 1.6, 9.5, etc.). What I'd like to do is output a simple line graph using these arrays, with the x axis being the frequency and the y axis the amplitude. I'm having difficulty figuring out how to input the arrays directly into the Google Charts code.
Currently, as a workaround, I’m trying to use an example that imports a json data file, by outputting the arrays in a format similar to the example I have, and then using that file as the data source. Not very eloquent and it will require me to link to a new page to read the data in the <head> section, rather than handling it all in one fell swoop with one script.
Hopefully, thus makes sense. I’m just a self-taught junky code hack.