How to Map incoming data to Line Chart

  • Shaila
    Participant
      6 years, 3 months ago #14371

      Hello Chris,

      I am geeting timeseries data from my connector and I am storing in global variable object but when I try to map this data to line chart.
      Issues:
      1. Line Chart sometime visible and sometimes not.
      2. when line chart is visible it does not show the mapped values on the graph.
      Can you please check whether we are doing mapping in the right format.
      Please find the attached screenshots.

      Thanks and regards,
      Shaila khot

      Attachments:
      You must be logged in to view attached files.
      Chris Bouveret
      Keymaster
        Has successfully completed the online course Introduction
        Has successfully completed the online course Intermediate (200)
        Has successfully completed the online course Advanced (300)
        Has successfully completed the online course Basics (100)
        Has successfully completed the online course Advanced (320)
        Has successfully completed the Intermediate Certification
        Has successfully completed the Advanced Certification
      6 years, 3 months ago #14416
      Up
      0
      Down
      ::

      Hi Shaila,

      i have created a transport for you with an example that contains chart and binding https://files.simplifier.io/f/bd71bb3e0c56487c95d6/?dl=1
      It is a transport for Simplifier 4.0 so please let me know which Version you use. I have seen that you have a registered freemium instance but it seems that you are working on a different instance right? Please see attached Screenshots as well

      Attachments:
      You must be logged in to view attached files.
      Shaila
      Participant
        6 years, 3 months ago #14422
        Up
        0
        Down
        ::

        Hi Chris,

        My current simplifier version is 3.5.74-LTS.152 and yes i am using different workspace. we have shared workspace so that other team members can also work on this application.

        Currently there is only one value is mapped and that to it is not attached to y axis .
        Please find the attached attached screenshot.

        Thanks
        Shaila

        Attachments:
        You must be logged in to view attached files.
        Chris Bouveret
        Keymaster
          Has successfully completed the online course Introduction
          Has successfully completed the online course Intermediate (200)
          Has successfully completed the online course Advanced (300)
          Has successfully completed the online course Basics (100)
          Has successfully completed the online course Advanced (320)
          Has successfully completed the Intermediate Certification
          Has successfully completed the Advanced Certification
        6 years, 3 months ago #14425
        Up
        0
        Down
        ::

        Hi Shaila,

        i updated your instance to 4.0 Release. You can now use the transport i provided to see the chart implementation

        BR
        Chris

        Shaila
        Participant
          6 years, 3 months ago #14426
          Up
          0
          Down
          ::

          ok thank you for that. I will import the file and check

          Regards,
          Shaila

          Shaila
          Participant
            6 years, 3 months ago #14427
            Up
            0
            Down
            ::

            Chris
            something really wrong happened I imported the file to as transport and then I do not see the any of app.
            can you please some how undo that. The work we have done i do not see that also.
            https://freemium-ny2i.simplifier.io/UserInterface/# this is the workspace i am using it.

            Thanks,
            Shaila

            Shaila
            Participant
              6 years, 3 months ago #14428
              Up
              0
              Down
              ::

              its working now I see my app and example apps. Thank you.

              Regards,
              Shaila

              Shaila
              Participant
                6 years, 3 months ago #14492
                Up
                0
                Down
                ::

                Hello Chris,
                I am trying to generate a line chart for the following data

                [90,0,20,0,85,30,40]

                I was successful in getting the charts but the graph plotted was for just first two values please check the image attached

                So to further investigate I put the console.log in widget Chart.js just before it generates the Chart as below

                generateChart: function() {
                            if (!this._chartInstance) {
                                
                                var data = {};
                                
                                if(this.generateLabels().length > 0) {
                                    data.labels = this.generateLabels();
                                }
                                
                                data.datasets = this.generateDatasets();
                                console.log("Debug to check dataset format");
                                console.log(JSON.stringify(data));
                                console.log(data);
                                
                                this._chartInstance = new Chart(this.getId() + "--canvas", {
                                    type: this.getChartType(),
                                    data: data,
                                    options: this._options
                                });
                                
                                this._options = this._chartInstance.options;
                            }

                so when I run your application (SIMP_Template_Charts) and my application (LOCOPE) and check the console.log I don’t see any differences, please find the output from my application below

                {“datasets”:[{“backgroundColor”:”#00AF00″,”borderColor”:”#00AF00″,”data”:[90,0,20,0,85,30,40],”fill”:false,”lineTension”:0,”pointRadius”:1}]}

                Can you please check my application “LOCOPE” and help me out figure out the problem.

                Thanks in adavance

                Regards,
                Shaila

                Attachments:
                You must be logged in to view attached files.
              Viewing 8 posts - 1 through 8 (of 8 total)

              You must be logged in to reply to this topic.