- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

How to set up a model to count trips starting and/or ending in the same municipality?
I have a challenging model for what you can compare to bus trips. I want to be able to count how many trips start in a municipality, how many trips end in a municipality and how many start and end in a municipality and region. Ideally, I would like this to be in the form of a drop-down, so when I select a municipality in a drop-down, I will get the number of trips that start and/or end in that municipality; all trips that only start + all the only ends + all that starts and ends.
muni1 | muni2 | muni3 | muni4 | |
start | 1 | 2 | 0 | 0 |
end | 2 | 1 | 0 | 0 |
total | 3 | 3 | 0 | 0 |
I have a model like the one below and pbix file can be downloaded here: https://we.tl/t-ZKpZxRRfsf (I thought I could attach to the post, but I didn't find anywhere to do it). I'm pretty sure, that is where the problem lies, so I would like any tips on enhancing this. But even if that is fixed, then I'm also looking for inspiration to create a measure, that will allow me to create a drop-down as mentioned.
Please let me know, if I can share any other relevant details.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hi @twowaysyellow ,
From what I can see from the model you shared theres is no relationship between the municipality and the bus travels. How do you identify that a certain trip is for a certain municipality?
The only one that is identified is the permanent stop id 210 but that is for municipality 4.
Can you explain a little better how you get to the numbers you present on top?
Regards
Miguel Félix
Did I answer your question? Mark my post as a solution!
Proud to be a Super User!
Check out my blog: Power BI em Português
Helpful resources
Subject | Author | Posted | |
---|---|---|---|
03-15-2024 01:02 PM | |||
04-08-2024 01:01 AM | |||
04-04-2024 12:32 PM | |||
12-05-2024 07:31 AM | |||
06-10-2024 02:35 AM |
User | Count |
---|---|
141 | |
110 | |
81 | |
61 | |
46 |