Could you create a separate sheet with the transposed data in it using the
Transpose formula?  That way, when the data is updated, the formula would
automatically create the updated transposed version of it.

To do this in JavaScript, here is an outline of the tasks:

   1. Fetch the data separately from the ChartWrapper, using a Query, as
   described here:
   
https://developers.google.com/chart/interactive/docs/spreadsheets#Google_Spreadsheets_as_a_Data_Source
   2. In the handler for the query response, create a new datatable, and
   iterate through the response.getDataTable() pulling out the right values to
   add to the new datatable.
   3. Then supply that new datatable to your chartwrapper, either when you
   construct the ChartWrapper, or by using setDataTable().  See
   
https://developers.google.com/chart/interactive/docs/reference#chartwrapperobject
   4. Finally call draw() on the chart wrapper.

There might be one alternative that is also not particular easy: use the
'pivot' clause in the Query:
https://developers.google.com/chart/interactive/docs/querylanguage#Pivot

On Wed, Oct 22, 2014 at 11:03 AM, Rob H <[email protected]> wrote:

> Many thanks Daniel
>
>>
> The spreadsheets we are going to be querying are to be updated
> automatically so there won't be any human interaction to use transpose.
>
> I'd love you to help with a javascript solution, I'm OK with javascript so
> if you could give me some help that would be great. I would also like to
> label each of the values if that's possible?
>
> Alternatively - I wonder - is there a way of finding out what row the UPN '
> 77abc' appears in and then I could query a range?
>
> Thanks :)
> Rob
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Chart 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-chart-api.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Daniel LaLiberte <https://plus.google.com/100631381223468223275?prsrc=2>  -
978-394-1058
[email protected] <[email protected]>   5CC, Cambridge MA
[email protected] <[email protected]> 9 Juniper Ridge
Road, Acton MA

-- 
You received this message because you are subscribed to the Google Groups 
"Google Chart 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-chart-api.
For more options, visit https://groups.google.com/d/optout.

Reply via email to