Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User
    Join Date
    Apr 2008
    Posts
    12
    Vote Rating
    0
    xnoor is on a distinguished road

      0  

    Exclamation Unanswered: sencha is plotting wrong on the chart !!

    Unanswered: sencha is plotting wrong on the chart !!


    hi all,

    im displaying a chart with the following json data

    HTML Code:
    [
        {
            "Read_Date": "2/29/2012",
            "num": 1,
            "DH_Pd": 4930,
            "DH_Pi": 944,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 414,
            "WHP": 414,
            "Amps": 53.666666666666664
        },
        {
            "Read_Date": "2/29/2012",
            "num": 2,
            "DH_Pd": 4938,
            "DH_Pi": 943,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 417,
            "WHP": 417,
            "Amps": 53.666666666666664
        },
        {
            "Read_Date": "2/28/2012",
            "num": 3,
            "DH_Pd": 4956,
            "DH_Pi": 951,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 434,
            "WHP": 434,
            "Amps": 54.333333333333336
        },
        {
            "Read_Date": "2/28/2012",
            "num": 4,
            "DH_Pd": 4954,
            "DH_Pi": 952,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 432,
            "WHP": 432,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/27/2012",
            "num": 5,
            "DH_Pd": 4985,
            "DH_Pi": 945,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 450,
            "WHP": 450,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/27/2012",
            "num": 6,
            "DH_Pd": 4981,
            "DH_Pi": 950,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 452,
            "WHP": 452,
            "Amps": 54.333333333333336
        },
        {
            "Read_Date": "2/26/2012",
            "num": 7,
            "DH_Pd": 4980,
            "DH_Pi": 949,
            "DH_Ti": 218,
            "DH_Tm": 230,
            "FLP": 442,
            "WHP": 442,
            "Amps": 54
        },
        {
            "Read_Date": "2/26/2012",
            "num": 8,
            "DH_Pd": 4981,
            "DH_Pi": 950,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 444,
            "WHP": 444,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/25/2012",
            "num": 9,
            "DH_Pd": 4986,
            "DH_Pi": 958,
            "DH_Ti": 218,
            "DH_Tm": 230,
            "FLP": 457,
            "WHP": 457,
            "Amps": 53.333333333333336
        },
        {
            "Read_Date": "2/25/2012",
            "num": 10,
            "DH_Pd": 0,
            "DH_Pi": 0,
            "DH_Ti": 0,
            "DH_Tm": 0,
            "FLP": 455,
            "WHP": 455,
            "Amps": 0
        },
        {
            "Read_Date": "2/24/2012",
            "num": 11,
            "DH_Pd": 4987,
            "DH_Pi": 953,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 452,
            "WHP": 452,
            "Amps": 54.333333333333336
        },
        {
            "Read_Date": "2/24/2012",
            "num": 12,
            "DH_Pd": 4985,
            "DH_Pi": 959,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 449,
            "WHP": 449,
            "Amps": 55
        },
        {
            "Read_Date": "2/23/2012",
            "num": 13,
            "DH_Pd": 4991,
            "DH_Pi": 962,
            "DH_Ti": 221,
            "DH_Tm": 231,
            "FLP": 463,
            "WHP": 463,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/23/2012",
            "num": 14,
            "DH_Pd": 4986,
            "DH_Pi": 968,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 458,
            "WHP": 458,
            "Amps": 54.333333333333336
        },
        {
            "Read_Date": "2/22/2012",
            "num": 15,
            "DH_Pd": 4990,
            "DH_Pi": 976,
            "DH_Ti": 219,
            "DH_Tm": 230,
            "FLP": 460,
            "WHP": 460,
            "Amps": 59.333333333333336
        },
        {
            "Read_Date": "2/22/2012",
            "num": 16,
            "DH_Pd": 5001,
            "DH_Pi": 974,
            "DH_Ti": 221,
            "DH_Tm": 231,
            "FLP": 465,
            "WHP": 465,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/21/2012",
            "num": 17,
            "DH_Pd": 5000,
            "DH_Pi": 973,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 465,
            "WHP": 465,
            "Amps": 54.333333333333336
        },
        {
            "Read_Date": "2/21/2012",
            "num": 18,
            "DH_Pd": 4988,
            "DH_Pi": 974,
            "DH_Ti": 220,
            "DH_Tm": 231,
            "FLP": 463,
            "WHP": 463,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/20/2012",
            "num": 19,
            "DH_Pd": 5003,
            "DH_Pi": 965,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 453,
            "WHP": 453,
            "Amps": 54.333333333333336
        },
        {
            "Read_Date": "2/20/2012",
            "num": 20,
            "DH_Pd": 5014,
            "DH_Pi": 975,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 457,
            "WHP": 457,
            "Amps": 55
        },
        {
            "Read_Date": "2/19/2012",
            "num": 21,
            "DH_Pd": 4991,
            "DH_Pi": 973,
            "DH_Ti": 220,
            "DH_Tm": 231,
            "FLP": 449,
            "WHP": 450,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/19/2012",
            "num": 22,
            "DH_Pd": 5012,
            "DH_Pi": 973,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 450,
            "WHP": 451,
            "Amps": 54.333333333333336
        },
        {
            "Read_Date": "2/18/2012",
            "num": 23,
            "DH_Pd": 4978,
            "DH_Pi": 975,
            "DH_Ti": 220,
            "DH_Tm": 231,
            "FLP": 446,
            "WHP": 446,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/18/2012",
            "num": 24,
            "DH_Pd": 0,
            "DH_Pi": 0,
            "DH_Ti": 0,
            "DH_Tm": 0,
            "FLP": 0,
            "WHP": 0,
            "Amps": 0
        },
        {
            "Read_Date": "2/17/2012",
            "num": 25,
            "DH_Pd": 5043,
            "DH_Pi": 952,
            "DH_Ti": 220,
            "DH_Tm": 231,
            "FLP": 445,
            "WHP": 445,
            "Amps": 55
        },
        {
            "Read_Date": "2/17/2012",
            "num": 26,
            "DH_Pd": 5020,
            "DH_Pi": 954,
            "DH_Ti": 220,
            "DH_Tm": 230,
            "FLP": 452,
            "WHP": 452,
            "Amps": 55
        },
        {
            "Read_Date": "2/16/2012",
            "num": 27,
            "DH_Pd": 5097,
            "DH_Pi": 979,
            "DH_Ti": 219,
            "DH_Tm": 231,
            "FLP": 516,
            "WHP": 518,
            "Amps": 55
        },
        {
            "Read_Date": "2/16/2012",
            "num": 28,
            "DH_Pd": 5108,
            "DH_Pi": 972,
            "DH_Ti": 220,
            "DH_Tm": 231,
            "FLP": 522,
            "WHP": 523,
            "Amps": 55
        },
        {
            "Read_Date": "2/15/2012",
            "num": 29,
            "DH_Pd": 5106,
            "DH_Pi": 978,
            "DH_Ti": 221,
            "DH_Tm": 231,
            "FLP": 531,
            "WHP": 531,
            "Amps": 53.666666666666664
        },
        {
            "Read_Date": "2/15/2012",
            "num": 30,
            "DH_Pd": 5079,
            "DH_Pi": 985,
            "DH_Ti": 221,
            "DH_Tm": 231,
            "FLP": 534,
            "WHP": 534,
            "Amps": 55
        },
        {
            "Read_Date": "2/14/2012",
            "num": 31,
            "DH_Pd": 5100,
            "DH_Pi": 983,
            "DH_Ti": 218,
            "DH_Tm": 231,
            "FLP": 528,
            "WHP": 528,
            "Amps": 55.666666666666664
        },
        {
            "Read_Date": "2/14/2012",
            "num": 32,
            "DH_Pd": 5101,
            "DH_Pi": 983,
            "DH_Ti": 218,
            "DH_Tm": 230,
            "FLP": 529,
            "WHP": 529,
            "Amps": 56.333333333333336
        },
        {
            "Read_Date": "2/13/2012",
            "num": 33,
            "DH_Pd": 5062,
            "DH_Pi": 980,
            "DH_Ti": 220,
            "DH_Tm": 231,
            "FLP": 519,
            "WHP": 519,
            "Amps": 54.666666666666664
        },
        {
            "Read_Date": "2/13/2012",
            "num": 34,
            "DH_Pd": 5079,
            "DH_Pi": 980,
            "DH_Ti": 220,
            "DH_Tm": 231,
            "FLP": 514,
            "WHP": 514,
            "Amps": 55
        },
        {
            "Read_Date": "2/12/2012",
            "num": 35,
            "DH_Pd": 5093,
            "DH_Pi": 983,
            "DH_Ti": 218,
            "DH_Tm": 231,
            "FLP": 525,
            "WHP": 525,
            "Amps": 59.333333333333336
        },
        {
            "Read_Date": "2/12/2012",
            "num": 36,
            "DH_Pd": 0,
            "DH_Pi": 0,
            "DH_Ti": 0,
            "DH_Tm": 0,
            "FLP": 0,
            "WHP": 0,
            "Amps": 0
        }
    ]
    with this script

    Code:
    var jsonData = eval(returnedJsonData);
    
        Ext.setup({
            tabletStartupScreen: 'tablet_startup.jpg',
            phoneStartupScreen: 'phone_startup.jpg',
            tabletIcon: 'icon-ipad.png',
            phoneIcon: 'icon-iphone.png',
            glossOnIcon: false,
            onReady: function () {
    
                function generateData() {
    
                    var d = new Date(jsonData[0].Read_Date);
                    //alert(jsonData.length);
    
                    data = [{
                        Read_Date: new Date(jsonData[0].Read_Date),
                        num: 0,
                        DH_Pd: jsonData[0].DH_Pd,
                        DH_Pi: jsonData[0].DH_Pi,
                        DH_Ti: jsonData[0].DH_Ti,
                        DH_Tm: jsonData[0].DH_Tm,
                        FLP: jsonData[0].FLP,
                        WHP: jsonData[0].WHP,
                        Amps: jsonData[0].Amps
                    }]
    
    
                    //alert(jsonData[0].Read_Date + '\n' + jsonData[0].DH_Pd + '\n' + jsonData[0].DH_Pi);
    
                    for (i = 1; i < jsonData.length; i++) 
                    {
                            data.push({
                            Read_Date: new Date(jsonData[i].Read_Date),
                            num: i,
                            DH_Pd: jsonData[i].DH_Pd,
                            DH_Pi: jsonData[i].DH_Pi,
                            DH_Ti: jsonData[i].DH_Ti,
                            DH_Tm: jsonData[i].DH_Tm,
                            FLP: jsonData[i].FLP,
                            WHP: jsonData[i].WHP,
                            Amps: jsonData[i].Amps
                        });
                        //alert(new Date(jsonData[i].Read_Date));
                        //                    alert(data[i].Read_Date + '\n' + data[i].DH_Pd + '\n' + data[i].DH_Pi);
    
                    }
                    return data;
                }
    
    
                var store = new Ext.data.JsonStore({
                    fields: ['Read_Date', 'num', 'DH_Pd', 'DH_Pi', 'DH_Ti', 'DH_Tm', 'FLP', 'WHP', 'Amps'],
                    data: generateData()
                });
    
                //store.loadData(generateData());
    
                var onRefreshTap = function () {
                    store.loadData(generateData());
                };
    
                new Ext.chart.Panel({
                    id: 'chartCmp',
                    title: '',
                    fullscreen: true,
                    //                dockedItems: {
                    //                    xtype: 'button',
                    //                    iconCls: 'shuffle',
                    //                    iconMask: true,
                    //                    ui: 'plain',
                    //                    handler: onRefreshTap,
                    //                    dock: 'left'
                    //                },
                    items: {
                        cls: 'stock1',
                        theme: 'Demo',
                        legend: {
                            position: {
                                portrait: 'right',
                                landscape: 'top'
                            },
                            labelFont: '17px Arial'
                        },
                        interactions: [
                        {
                            type: 'panzoom',
                            axes:
                            {
                                left:
                                {
                                    maxZoom: 2
                                },
                                bottom:
                                {
                                    maxZoom: 4
                                },
                                right:
                                {
                                    minZoom: 0.5,
                                    maxZoom: 4,
                                    allowPan: false
                                }
                            }
                        }, {
                            type: 'iteminfo',
                            listeners: {
                                show: function (interaction, item, panel) {
                                    var storeItem = item.storeItem;
                                    panel.update(['<ul><li><b>DH_Pi: </b>' + storeItem.get('DH_Pi') + '</li>', '<li><b>Value: </b> ' + item.value[1] + '</li></ul>'].join(''));
                                }
                            }
                        }],
                        animate: true,
                        store: store,
                        axes: [{
                            type: 'Numeric',
                            position: 'left',
                            fields: ['DH_Pd','DH_Pi','FLP', 'WHP'],
                            title: 'Pi - Pd - FLP - WHP'
                        }, {
                            type: 'Numeric',
                            position: 'right',
                            fields: ['Amps', 'DH_Ti', 'DH_Tm', ],
                            title: 'Amps - Ti - Tm'
                        }, {
                            type: 'Time',
                            position: 'bottom',
                            fields: ['Read_Date'],
                            dateFormat: ' M d ',
                            label: {
                                rotate: {
                                    degrees: 45
                                }
                            }
                        }],
                        series: [{
                            type: 'line',
                            showMarkers: true,
                            fill: false,
                            axis: 'left',
                            xField: 'Read_Date',
                            yField: 'DH_Pd'
                        }, {
                            type: 'line',
                            showMarkers: true,
                            fill: false,
                            axis: 'left',
                            xField: 'Read_Date',
                            yField: 'DH_Pi'
                        }, {
                            type: 'line',
                            showMarkers: true,
                            fill: false,
                            axis: 'right',
                            xField: 'Read_Date',
                            yField: 'DH_Ti'
                        }, {
                            type: 'line',
                            showMarkers: true,
                            fill: false,
                            axis: 'right',
                            xField: 'Read_Date',
                            yField: 'DH_Tm'
                        }, {
                            type: 'line',
                            showMarkers: true,
                            fill: false,
                            axis: 'left',
                            xField: 'Read_Date',
                            yField: 'FLP'
                        }, {
                            type: 'line',
                            showMarkers: true,
                            fill: false,
                            axis: 'left',
                            xField: 'Read_Date',
                            yField: 'WHP'
                        }, {
                            type: 'line',
                            showMarkers: true,
                            fill: false,
                            axis: 'right',
                            xField: 'Read_Date',
                            yField: 'Amps'
                        }]
                    }
                });
            }
        });
    but there is something strange happening, its plotting wrong values on the charts

    here is a screenshot of the chart

    http://www.tiikoni.com/tis/view/?id=8f0c0ea

    its reaching up to 10000 and actually, this value doesn't exist..

    any help would be appreciated..
    Regards,
    Noureddine El-Zaatari
    GIS Developer
    Blog: www.xnoor.com
    [B][COLOR="DarkOrange"]"don

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,704
    Answers
    3356
    Vote Rating
    750
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    I have removed your other post. Please don't post duplicates.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Apr 2008
    Posts
    12
    Vote Rating
    0
    xnoor is on a distinguished road

      0  

    Talking


    hi,

    is this a bug or something ??
    Regards,
    Noureddine El-Zaatari
    GIS Developer
    Blog: www.xnoor.com
    [B][COLOR="DarkOrange"]"don

Thread Participants: 1

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar