cancel
Showing results forĀ 
Search instead forĀ 
Did you mean:Ā 
Subscribe

Would like to check is it possible to create a multi lines chart because no matter how I play with the feed item, it seems that I am only able to get a single line chart with the vizType : 'line'.

Something similar to what is below.

http://m.eet.com/media/1159896/coupling-a-supercapacitor-with-a-small-energy-harvesting-source-fig-6.jpg

0 Likes
View Entire Topic
Former Member
0 Likes

thanks Oliver Jordan helping me explain what I really want to achieve.

dominik-st
Participant
0 Likes

Hi,

for building a multi line chart using a VizFrame  and posted a solution in my thread

Maybe this helps...

Best regards

Dominik

Rudy_Clement1
Participant
0 Likes

Hi Beck,

You should define 1 measure and 2 dimensions like this:


     var oDataset = new sap.viz.ui5.data.FlattenedDataset({

           dimensions: [

               { name: "model", value: "{model}" },

               { name: "time", value: "{time}" }],

            measures: [

       { name : "current", value : "{current}" }],

            data: {

                path: "/Electrical"

            }

        });

Then you should define 3 feed items referring to these measures and dimensions like this:


        var feedValueAxis = new sap.viz.ui5.controls.common.feeds.FeedItem({

                "uid": "valueAxis",

                "type": "Measure",

                "values": "current"

            }),

            feedCategoryAxis = new sap.viz.ui5.controls.common.feeds.FeedItem({

                "uid": "categoryAxis",

                "type": "Dimension",

                "values": "time"

            });

            feedColor = new sap.viz.ui5.controls.common.feeds.FeedItem({

                "uid": "color",

                "type": "Dimension",

                "values": "model"

            });

Finally add the feed items to the VizFrame:


        oVizFrame.addFeed(feedValueAxis);

        oVizFrame.addFeed(feedCategoryAxis);

        oVizFrame.addFeed(feedColor);

Then it should look like this:

Kind regards,

Rudy.