Skip to Content
0

UI5 stacked_bar vizFrame with target line

Nov 21, 2017 at 09:00 PM

98

avatar image

Hi all

I am struggling to produce a stacked_column (or stacked_bar for that matter)chart using UI5 vizFrame, which displays 3 values and also showing a target line on the same bar/column.

What I can do is successfully create a stacked_column with the 3 values:

https://jsfiddle.net/wdfm31m1/4/

and also a bullet chart which displays from what I can tell no more than 2 values and a target:

https://jsfiddle.net/wdfm31m1/1/

I feel like I must be missing something obvious. Can anyone tell me how I should go about achieving this please?

Many thanks

Phil

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Iftah Peretz
Nov 22, 2017 at 01:36 PM
0

Hey,

I think this will cover your demands. See the "2 Series" and "Primary + Additional" options.

Show 3 Share
10 |10000 characters needed characters left characters exceeded

Thanks for the quick response.

I had previously seen this, however I still cannot see how to add the third measure to the column.

I have added a third measure to the example here

https://jsfiddle.net/vb1mzmb2/1/

by adding to the data a value of "Due Very Soon" and then added this to the array of measures:

       measures: [
                {name: 'Due Now', value: '{Due Now}'},
                {name: 'Due Soon', value: '{Due Soon}'},
                {name: 'Due Very Soon', value: '{Due Very Soon}'},
                {name: 'Target', value: '{Target}'}                
            ],

and, also added this to the feed:

sap.viz.ui5.controls.common.feeds.FeedItem({
            'uid' : "valueAxis",
            'type' : "Measure",
            'values' : ["Due Now", "Due Soon", "Due Very Soon"]
        }),

...however, the third value does not appear, only the original 2! As with the example you have linked they still only show two measures per bar/column whereas I need three for my scenario. Am I missing something?

What I need to end up with is something like this crude photoshop:

Thanks again

Phil

0

Based on this you can "express an additional value..." the emphasis is on value and not values.

To achieve what you want, you need to use Combined Stacked Column and Line Chart like here.

0

Thanks again for following up on this, unfortunately the combination chart also will not work (visually) as the target value only holds reference to each category in isolation rather than being a series in its own right.

Appreciate the time you have put in to help.

Cheers

Phil

0