9 Replies Latest reply: Nov 8, 2011 5:25 AM by rizo98

# how to show marketshare in bar chart

Hi guys

complete newbie to QV

I have prepared what is in the image below.

I want to be able to calculate the market share of each Salesman ID and show it on the chart.

I think the ideal chart type for this is combo chart.

Any ideas how I do this please?

I specifically need the expression and need to be told where to put it.

cheerz guys

I have a

• ###### how to show marketshare in bar chart

you can take another expression of market share in this bar chart which shows market share of each salesman.

but if you want to show market share then this can better describe through pie chart.

but if you want to show in this graph only then simply add the expression for market share.

this expression you have to decide as i don't know your database.

• ###### how to show marketshare in bar chart

I have learned how to do the marketshare in a pie chart.

All I want to do is simply devide the total of each individual by everyones total.

Where sum(sales) for salesman_ID 2002 is 178389 (as shown in image), and the whole sales total is 2317233

I want to do this  =178389/2317233

and show it as percentage in the chart as a line graph.

hope I'm clear

• ###### how to show marketshare in bar chart

Hi rizo,

sum(sales)/sum(TOTAL (sales)).

After that you can chose how you want to display the expression. Chose "Line" and if you want to see the Values chose "Values on Data Points". To see this Values as percentage, go to the Number tab and chose "Show in Percent".

Regards

David

• ###### how to show marketshare in bar chart

I tried that except i didnt put TOTAL (sales) in brackets.

I will try this tonight and horefully it'll work.

thanks for the the help

• ###### how to show marketshare in bar chart

aggr(sum(sales),salesmanID)/sum(sales)

hope this expression will work.

try it out.

• ###### how to show marketshare in bar chart

will try em and ley you guys know

• ###### how to show marketshare in bar chart

just some feedback guys.

they didnt work because i had 2 dimensions set.

but thet did work when i removed one.

so both expressions are correct.

thanks for the help guys

• ###### how to show marketshare in bar chart

Rizo98

Make sure you have the Combo chart type selected and set one expression to be a bar and the other to be a line. When you then look at the AXIS tab you can set each dimension to have a seperate axis which should then allow you to have both expressions on the same chart

Ta

Lewis

• ###### how to show marketshare in bar chart

i did just that.

thanks