pareto
12 TopicsDynamic Pareto chart - with field parameters not working
Hello, I have a working Pareto measure with one "sub category" working, but I can't change that to dynamic working with a field parameter here is the measure Pareto % = IF( 1, //ISINSCOPE(par_stop_category[par_stop_category Name]), VAR __AllselectedStops = ALLSELECTED(dim_stop_code[hrm_description]) VAR __StopTable = ADDCOLUMNS(__AllselectedStops, "@Count", [Stops #]) VAR __CurrentCount = [Stops #] VAR __CumStopTable = FILTER(__StopTable, [@Count] >= __CurrentCount) VAR __CumStop = SUMX( __CumStopTable, [@Count]) VAR __AllSelectedStopsCount = CALCULATE([Stops #], __AllselectedStops) VAR __Result = DIVIDE(__CumStop, __AllSelectedStopsCount) RETURN IF(__CurrentCount > 0, __Result, BLANK()) ) my field parameter look like this par_stop_category = { ("Main", NAMEOF('dim_stop_code'[mn_description]), 1,"Main"), ("Harm", NAMEOF('dim_stop_code'[hrm_description]), 0,"Harm"), ("Place", NAMEOF('dim_stop_code'[plc_description]), 2,"Place"), ("Reason", NAMEOF('dim_stop_code'[rsn_description]), 3,"Reason"), ("Code", NAMEOF('dim_stop_code'[code_description]), 5,"Code"), ("Category", NAMEOF('dim_stop_code'[ctgry_description]), -1,"Category"), ("Group", NAMEOF('dim_stop_code'[grp_description]), 1,"Group"), //ERROR ("Error Place", NAMEOF('dim_error_code'[erplc_description]), 8,"Error Place"), ("Error Code", NAMEOF('dim_error_code'[errcd_description]), 9,"Error Code") } both are working fine with themselfes, but when I try to create a dynamic pareto, it's not working any more cause of the error "The ADDCOLUMNS function expects a table expression for argument '', but a string or numeric expression was used." here my dynamic Pareto Measure Pareto % = IF( 1, //ISINSCOPE(par_stop_category[par_stop_category Name]), // VAR __AllselectedStops = ALLSELECTED(dim_stop_code[hrm_description]) VAR __AllselectedStops = SWITCH( SELECTEDVALUE(par_stop_category[par_stop_category Name]), "Main", ALLSELECTED(dim_stop_code[mn_description]), "Harm", ALLSELECTED(dim_stop_code[hrm_description]), "Place", ALLSELECTED(dim_stop_code[plc_description]), "Reason", ALLSELECTED(dim_stop_code[rsn_description]), "Code", ALLSELECTED(dim_stop_code[code_description]), "Category", ALLSELECTED(dim_stop_code[ctgry_description]), "Group", ALLSELECTED(dim_stop_code[mn_description]), "Error Place", ALLSELECTED(dim_error_code[erplc_description]), "Error Code", ALLSELECTED(dim_error_code[errcd_description]) ) VAR __StopTable = ADDCOLUMNS(__AllselectedStops, "@Count", [Stops #]) VAR __CurrentCount = [Stops #] VAR __CumStopTable = FILTER(__StopTable, [@Count] >= __CurrentCount) VAR __CumStop = SUMX( __CumStopTable, [@Count]) VAR __AllSelectedStopsCount = CALCULATE([Stops #], __AllselectedStops) VAR __Result = DIVIDE(__CumStop, __AllSelectedStopsCount) RETURN IF(__CurrentCount > 0, __Result, BLANK()) ) maybe somebody have some good ideas 🙂Solved1.7KViews0likes6CommentsOtimização DAX para cálculo acumulado
Olá pessoal, Preciso melhorar o código do cálculo faturamento acumulado por cliente e % acumulado do faturamento por clinete, pois o que fiz está com a performance ruim, está demorando muito para mostrar o resultado e quando realizo a publicação do Dashboard ele excede o limite de processamento. Faturamento acumulado cliente = VAR vFatContexto = [Total vendas] VAR vFatTotal = CALCULATE([Total vendas],ALLSELECTED(TB_CLIENTES[CODIGO CLIENTE])) VAR VfatAcum = CALCULATE( [Total vendas], FILTER( ALLSELECTED(TB_CLIENTES[CODIGO CLIENTE]), [Total vendas] >= vFatContexto ) ) RETURN VfatAcum % Acum Fat Cliente = VAR vFatTotal = CALCULATE([Total vendas], ALLSELECTED(TB_CLIENTES[CODIGO CLIENTE])) RETURN DIVIDE([Faturamento acumulado cliente],vFatTotal) Alguém poderia me ajudar a melhorar?Solved14KViews0likes3CommentsApplying Pareto Analysis 3 times for classifying Customers
hello friends, I want to do classification on my customers based on pareto rule but in my own way. My Classes Are : A+ , A , B and C For emxample, I have total number of 1000 customers summrized by their Sales Amount. I want to do pareto Analysis 3 times to group my customers like below : For example : Step 1 : 1000 customer : 80% of Sales (400 Customers)-----20% of Sales (600 Customers) So 600 customers = Class C Step 2 : 400 customer : 80% of Sales (250 Customers)-----20% of Sales (150 Customers) So 150 customers = Class B Step 3 : 250 customer : 80% of Sales (80 Customers)-----20% of Sales (170 Customers) So 170 customers = Class A and 80 Customers A+ Class. It would be appretiated if you guys help me do this either in Powerpivot using dax or Power Bi. So that I could have the list of each customers and dynamically filter through different categories in my data model.622Views0likes1CommentTo group a numeric column containing the difference between 2 dates into same_day, day+1, >1 day
i want to convert a numeric column containing difference between 2 dates like (0,1,2,3..... so on) into 3 groups --> same_day, d+1 and >1 day How to convert the numeric column and categorize them into 3 groups? days between (difference b/w 2 dates)| ---> | 3 categories 0 same day 1 D+1 day 2 >1 day 3 >1 day .... 6 >1 daySolved860Views0likes2CommentsRank on two tables visuals
Hi! What I want to do is: If the ParameterName in Table 1 have the rank of 1, then I want the ParameterName in Table 2 to be shown first/on top (even if that ParameterName doesn't have rank 1, or the highest diff in MovingAverage). //It is something with Pareto apparently Is it possible? Note that I am not talking abput tables where I have different columns/calc columns, but instead table visuals. I have tried googling but everytime they think I mean a full table..Solved1.1KViews0likes3CommentsPareto values used in a text box (scalar values)
Hello community, hope someone can help me before my head explodes. I searched for days now, but could not find an answer. Here is the challenge: I am working on a pareto chart, which wasn't that complicated to create a table and a chart out of it (see attached PBIX with demo data), thanks to some awesome guys and their videos. Pareto Running Total ParetoTest RT simple = CALCULATE([Paretotest Total Sales], FILTER( ALL( ParetoTestData[Customer]), sum(ParetoTestData[Amount]) <= [Paretotest Total Sales])) Pareto % RT Paretotest RT % simple = DIVIDE([ParetoTest RT simple],[Paretotest total All Sales],0) Now I want to put this information in a text box saying: "In the country XYZ, n out of m customers (20%) made A USD (80% of total sales of B USD)" The easy ones are: m = all customers (in this country) B = all sales in this country But I also need the scalar values for n and A: n = Count of customers which represent A = 80% of the sales (and this value should be the calculated pareto running total, not simply 80% of the sales) In my example the text card should say: "In country XYZ 2 customers (20% of customers) represent 35300 USD (81.0% of sales)". Please ignore the country selection for now to make it as simple as possible. Hope someone really smart can help me ..... please Thanks Benedikt https://app.powerbi.com/view?r=eyJrIjoiODQzOWJiZDItODY2Yy00Y2UwLTlmNDQtY2E3ZDk4NGIwOGU2IiwidCI6IjU0OGVmYThjLWI1MzEtNDRjOS05MGY4LTAzZDc4MTdkMzdmZSJ9Solved2.3KViews0likes8CommentsAdding 2 custom lines to line and stacked column chart
I currently have a pareto chart by number of cases per event date. I'm trying to add a rolling 7 day average calculation to this but I keep getting: Where I was hoping to have something like this? I'm currently running my 7 day rolling average by [Event Date]: 7 Day Rolling Average - Notification Date = CALCULATE(SUM('Sheet1'[Epi Date Count]),DATESINPERIOD('Sheet1'[Event Date],LASTDATE('Sheet1'[Event Date]),7,DAY)) / CALCULATE(DISTINCTCOUNT('Sheet1'[Event Date]),DATESINPERIOD('Sheet1'[Event Date],LASTDATE('Sheet1'[Event Date]),7,DAY)) Is there any way this can be done? Thanks in advance Please find file attached https://www.dropbox.com/s/c3hfci8jabydxv1/Pareto.pbix?dl=02KViews0likes4CommentsCumulative Frequency curve adjusted x axis
I'm currently trying to build a pareto chart from a list of dates and I've populated the following table: Total Number Rank Cumulative Total Total Incidents % Month/Year 25450 1 25450 63275 40.22 Oct 2020 17602 2 43052 63275 68.04 Apr 2020 7576 3 50628 63275 80.01 Sep 2020 4518 4 55146 63275 87.15 May 2020 3263 5 58409 63275 92.31 Mar 2020 2920 6 61329 63275 96.92 Aug 2020 763 7 62092 63275 98.13 Nov 2020 699 8 62791 63275 99.24 Jul 2020 484 9 63275 63275 100 Jun 2020 My rank is built from the month/year column: Rank = IF( ISBLANK('Sheet1'[Total Number]) || NOT HASONEVALUE('Sheet1'[Month/Year]), BLANK(), RANKX(ALL('Sheet1'[Month/Year]), ([Total Number]))) However I keep ending up with this: Where i'd like to have the same cumulative frequency line but the Dates in order as when I change it I end up with: Is there a way to fix this pareto chart with the correct x-axis? https://www.dropbox.com/s/c3hfci8jabydxv1/Pareto.pbix?dl=0Solved2.2KViews0likes5CommentsPareto Curve in Power BI/DAX - % customers vs % sales
Hello dear community members, I've been trying to solve this for a while, but not luck so far. I need to have a 'Sales Concentration Curve', that is a Pareto curve basically, but instead of having CUSTOMERS on the X-Axis, having a percentage (i.e: X% of customers give Y % of volume). I got this for now: It only works if I add the Bar values (that is sales value) which is basically Sum of Sales Value. and creating the following measure which draws the curve using the below code: Cust volume Concentration = VAR total_SalesVol = CALCULATE(SUM(oos_master_customer[Sales LY]),ALLSELECTED(oos_master_customer)) VAR current_SalesVol = SUM(oos_master_customer[Sales LY]) VAR summarized_Table = SUMMARIZE( ALLSELECTED(oos_master_customer), oos_master_customer[customer_unique_code], "volume",SUM(oos_master_customer[Sales LY]) ) VAR CumulativeSum = SUMX( FILTER(summarized_Table,[volume] >= current_SalesVol), [volume] ) RETURN DIVIDE(CumulativeSum,total_SalesVol) The curve is redrawn appropriatly when applying filters on the graph. So all works perfectly. What I am missing: is to have on the X-axis, instead of the customer (11k of them), just percentage 0-100% based on their ranking of largest to smallest. My model has: 1 Transaction (facts) table for sales linked to 1 Customer (Dim) table linked to 1 Product (Dim) table (to the facts table obviously) Thanks a lot I spent too many hours trying to figur that out - your help is very much appreciated. thanks a lot2.4KViews0likes4CommentsNeed help on tool tip - Pareto Analyis
Hi Team, I need help on concatenatex in the Dax expression. Please find the below Clustered Column chart's tool tip. Help me on the below, 1. Need Distinct values. The values are repeating ex : P4,P4 in the second bar. 2. Single value should appear on 4th & 5th bar. now its showing P2, P5 on both bars. Details (Pareto analysis) : The data is simplified, it has Brand, Product, GMV value. Based on GMV value the Share after filteres applied needs to be calculated. The cut-off is 80% to be labelled as Power Product/ not amongst the selections. On labeling the product either as Power/not the Stock status count is required as below but the tool tip is not correct. Sample PBIX file attached. https://drive.google.com/file/d/1nHRLqw13pXKVHSr1QI2urk-BWq6D9XF1/view?usp=drivesdk Regards, Arjun DNSolved2.1KViews0likes10Comments