Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Solved! Go to Solution.
Hi @Sweetcapitan,
Please create a measure like below:
Running total = CALCULATE ( SUM ( 'Plotting Curves'[Y] ), FILTER ( ALLEXCEPT ( 'Plotting Curves', 'Plotting Curves'[Z] ), 'Plotting Curves'[X] <= MAX ( 'Plotting Curves'[X] ) ) )
Then, add corresponding fields and above measure into a line chart.
Best regards,
Yuliana Gu
Sure, any chance of some sample data + a screenshot showing how it would look if you used Excel. This will make it easier build (plus help clarify any questions)
Thanks Phil!
Here is the data.
Y is the response so the outcomes are Y (1) or N (0).
X is time of response.
Z is the test group. The data here shows 2 groups - A and B.
time | resp | group |
X | Y | Z |
1 | 1 | A |
2 | 0 | A |
2 | 1 | A |
2 | 0 | A |
2 | 1 | A |
2 | 0 | A |
3 | 1 | A |
3 | 0 | A |
3 | 1 | A |
3 | 0 | A |
3 | 1 | A |
3 | 0 | A |
3 | 1 | A |
3 | 0 | A |
1 | 1 | B |
1 | 0 | B |
1 | 1 | B |
1 | 0 | B |
2 | 1 | B |
2 | 0 | B |
2 | 1 | B |
2 | 1 | B |
2 | 1 | B |
2 | 1 | B |
3 | 1 | B |
3 | 1 | B |
3 | 1 | B |
3 | 1 | B |
3 | 1 | B |
3 | 1 | B |
3 | 1 | B |
in Excel I would create a pivot table to summarize the results to get two series (A and B) of responses against time (table 1). Then I would cumulate it as table 2 and feed it to create the final chart, which is the visual I would like to create in Power BI. Thanks!
Hi @Sweetcapitan,
Please create a measure like below:
Running total = CALCULATE ( SUM ( 'Plotting Curves'[Y] ), FILTER ( ALLEXCEPT ( 'Plotting Curves', 'Plotting Curves'[Z] ), 'Plotting Curves'[X] <= MAX ( 'Plotting Curves'[X] ) ) )
Then, add corresponding fields and above measure into a line chart.
Best regards,
Yuliana Gu
Ah ha, I got it! Thanks a lot @v-yulgu-msft!
Now I encounter another issue. Since each test is conducted at different time, the length of response curve varies (chart 1). When I plotted the curve with the help of your answer, I got chart 2 below - basically the curve drop to zero where there is no data at the response date (x axis). How should I solve this?
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
96 | |
77 | |
66 | |
53 |
User | Count |
---|---|
144 | |
105 | |
102 | |
89 | |
63 |