Your jsonData.forEach function is not parsing your data correctly.  Take a 
look at that function to figure out how you need to change it to match your 
data.  I suspect that you want something like this:

jsonData.forEach(function(a) {
    a.dates.forEach(function(d) {
        dataFields.forEach(function(f) {
            // do stuff
        });
    });
});

On Tuesday, July 8, 2014 2:23:53 PM UTC-4, Neil Camara wrote:
>
> I'm using Google's ng-google-chart.js. This is the exact link - 
> https://github.com/bouil/angular-google-chart
>
>
>
> On Tuesday, July 8, 2014 12:24:39 PM UTC-5, Andrew Gallant wrote:
>>
>> With that, $scopde.odometerChart is the object returned by plotHourly, 
>> but what are you using to turn that code into a chart object (or 
>> ChartWrapper, or something else?) and how are you drawing the chart?
>>
>> On Tuesday, July 8, 2014 10:11:19 AM UTC-4, Neil Camara wrote:
>>>
>>> This is the code that will receive the chart.
>>>
>>> <div google-chart chart="odometerChart"></div>
>>>
>>> This is the code that will plot the graph. The first param is the json 
>>> data. Second one is just color. Third is for the title of the chart but I 
>>> left it empty. The 'datetime' is a property in the jsondata and 
>>> odometerInchesPrinted is another property too but has the number value. 
>>> Refer to my earlier plotHourly function in the gist.
>>>
>>> $scope.odometerChart = plotHourly(tmpDeviceModels[0].dates, 
>>> $scope.iconColor1, '', 'datetime', 'odometerInchesPrinted');
>>>
>>> Fyi, this is Angular.
>>>
>>> On Monday, July 7, 2014 8:56:25 PM UTC-5, Andrew Gallant wrote:
>>>>
>>>> Can you also post the code where the chart is drawn?  I'm trying to 
>>>> replicate your setup as exactly as I can (as far as the chart is 
>>>> concerned) 
>>>> so I can figure out what we need to do to get this to display the way you 
>>>> want.
>>>>
>>>> On Monday, July 7, 2014 1:59:58 AM UTC-4, Neil Camara wrote:
>>>>>
>>>>> Here it is Andrew. Sorry, I was all day out in my garden. :)
>>>>>
>>>>> https://gist.github.com/c0debreaker/4e4944c382ac44757db4
>>>>>
>>>>> On Sunday, July 6, 2014 2:37:42 PM UTC-5, Andrew Gallant wrote:
>>>>>>
>>>>>> Can you post a sample of the jsonData contents?
>>>>>>
>>>>>> On Sunday, July 6, 2014 2:44:07 AM UTC-4, Neil Camara wrote:
>>>>>>>
>>>>>>> Hi Andrew,
>>>>>>>
>>>>>>> This is the code I wrote that will parse our custom json data.
>>>>>>>
>>>>>>> https://gist.github.com/c0debreaker/d866cbfdf5f40e315a55
>>>>>>>
>>>>>>> I'm using string and number types.
>>>>>>>
>>>>>>> Also, I have other questions :)
>>>>>>> 1. How can I add that single vertical line on the chart? All of my 
>>>>>>> charts only have horizontal lines.
>>>>>>> 2. There are chart design drawn by our design where it doesn't 
>>>>>>> display the text for the y-axis. How do I prevent it from showing up? 
>>>>>>> Once 
>>>>>>> it's gone, I need to add a text at the bottom center of the chart(where 
>>>>>>> y-axis text where). An example text that I am seeing on the drawing is 
>>>>>>> "June 2014".
>>>>>>>
>>>>>>> Thanks a lo!
>>>>>>>
>>>>>>>
>>>>>>> On Saturday, July 5, 2014 10:40:40 AM UTC-5, Andrew Gallant wrote:
>>>>>>>>
>>>>>>>> The short answer is yes, you can display hours like that.  How you 
>>>>>>>> go about it depends on how your data is structured.  Are you using the 
>>>>>>>> "timeofday" or "datetime" data types, or are you using "string" or 
>>>>>>>> "number" 
>>>>>>>> types?  If you provide a code sample for generating your chart, I can 
>>>>>>>> work 
>>>>>>>> with you to figure out how to make the hours display correctly.
>>>>>>>>
>>>>>>>> On Saturday, July 5, 2014 2:12:47 AM UTC-4, Neil Camara wrote:
>>>>>>>>>
>>>>>>>>> I forgot to mention that I still have to show all 24 hour data.
>>>>>>>>>
>>>>>>>>> On Saturday, July 5, 2014 1:08:51 AM UTC-5, Neil Camara wrote:
>>>>>>>>>>
>>>>>>>>>> Hi folks,
>>>>>>>>>>
>>>>>>>>>> I was given this design by our designer. Is it possible to 
>>>>>>>>>> display the hour similar to the image below? 3:00   6:00  9:00 and 
>>>>>>>>>> so on
>>>>>>>>>> if it is, can someone please make a plunkr?
>>>>>>>>>>
>>>>>>>>>> http://i.imgur.com/BUmOSDn.png
>>>>>>>>>>
>>>>>>>>>> Thanks in advance!
>>>>>>>>>>
>>>>>>>>>> Neil
>>>>>>>>>>
>>>>>>>>>>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Visualization API" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-visualization-api+unsubscr...@googlegroups.com.
To post to this group, send email to google-visualization-api@googlegroups.com.
Visit this group at http://groups.google.com/group/google-visualization-api.
For more options, visit https://groups.google.com/d/optout.

Reply via email to