Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • timmysileshi Friend
    #977842

    Trying to use JA Google Charts Module with data coming from Google Sheets, which has empty/blank/null cells in the table. This results in two undesired results.

    1. 1 – using JA Google Chart V1.02 – Line graph will consider null values as zero.
    2. 2 – using JA Google Chart 2 V 1.0 – Line graph will appear as dots (not connected)

    If generating the Line Graph in Google Sheets, there’s a feature called "Plot null values" and that takes care of the issue. Please advise if I missed something in the configuration of the module, or if there will be an update incorporating such feature.


    1. Snap-2016-10-18-at-20.29.48
    2. Snap-2016-10-18-at-20.29.10
    Ninja Lead Moderator
    #977967

    Hi,

    I configured the JA Google Chart 2 at my end but it’s working as well

    I’m not quite sure what configuration you have done on your site? If possible, you can provide me the credentials info: URL, admin account via private reply. I will check further.

    Regards


    1. Screen-Shot-2016-10-19-at-11.49.32
    timmysileshi Friend
    #978209
    This reply has been marked as private.
    Ninja Lead Moderator
    #978312

    Hi,

    That’s a bug from our product and I also raised this bug to development team and you can check the status it here

    Regards

    timmysileshi Friend
    #979151

    Thank you for the quick response. I implemented the suggested code changes. I feel that we’re half way to the solution. The changes do "Plot null values", unfortunately as a value of 0. That was not the desired outcome I intended. While my data table has missing data for each record, the chart should be formed using only available data, and not consider null (unavailable) data as zero. Please see google’s charting options in the attachment. I am using the same spreadsheet for this example.
    Google chart does not consider empty cells as 0 values.

    The same graph in Excel, would be configured as follows "Connect data points with line" (see attachment) to get the desired result.


    1. Snap-2016-10-21-at-14.20.04
    2. Snap-2016-10-21-at-14.19.48
    3. Snap-2016-10-21-at-14.53.50
    Ninja Lead Moderator
    #979508

    You can apply my hotfix below with the problem on JA Google Chart 2 module

    • Download and unzip my attached files

    • Copy them to modules/mod_jagooglechart_2/asset/google-chart.js and modules/mod_jagooglechart_2/asset/elements/asset/js/script.js file

    • Don’t forget to make a backup file of your site first

    Hope it helps


    timmysileshi Friend
    #979578

    Thank you for the response. Unfortunately , even after replacing both java script files, I couldn’t find the option to configure this in the chart configuration page of the Module. The chart is still plotting null as 0 [Zero]. I still don’t see the desired result. After numerous hours of googling, I did figure out how to correct the issue using google charts though. The trick was to have

    interpolateNulls: true

    in the options for the chart. see http://amen.sileshi.com/charts and compare with http://amen.sileshi.com/ [ same data source, just the interpolateNulls option applied on the charts page]

    I still hope that you figure out a way to implement this change.

    Ninja Lead Moderator
    #979991

    Hi,

    Use these attached file again and copy them to path below

    modules/mod_jagooglechart_2/asset/google-chart.js
    modules/mod_jagooglechart_2/asset/elements/assets/js/script.js
    modules/mod_jagooglechart_2/mod_jagooglechart_2.php

    Let me know how it goes.
    Regards


    1. hotfix.zip
    timmysileshi Friend
    #980190

    YES! YES! YES!
    IT WORKS AS INTENDED!

    THANK YOU! THANK YOU!

    Now, will your module be updated for future downloads? If I want to implement to another site, will I be able to download an updated module with your changes, or do I have to apply the hotfix myself?

    Again,
    Thanks!

    Ninja Lead Moderator
    #980354

    Hi,

    I will pass to the team and it will be updated in upcoming released version.

    Regards

Viewing 10 posts - 1 through 10 (of 10 total)

This topic contains 9 replies, has 2 voices, and was last updated by  Ninja Lead 2 years, 8 months ago.

We moved to new unified forum. Please post all new support queries in our New Forum