Forum Discussion
Plot a line on a Map
Hi All,
I have a request for the ability to show routes on a map in a Power BI report. The user has a list of routes with origins and destinations. They would like an arc drawn between each of the origin and destination points and for these to be selectable in order to filter data in the dashboard.
I cannot find any obvious way to do this in the existing map controls. Does anyone know of a custom visual that would allow this. it seems like a useful addition for the many companies that deal with route related information
Thanks in advance
- Anonymous9 years ago
You can't do this in any of the existing map visuals but there is a possible R script solution here.
You may follow the tutorial to create the custom visual. The developer tools can be used to build R Powered Custom Visual as well.
9 Replies
- AnonymousNot applicable
You can't do this in any of the existing map visuals but there is a possible R script solution here.
- IainMacnabRegular Visitor
Many thanks,
Never used R before but it will be an interesting exercise
Thanks for taking the time to reply!!!
- AnonymousNot applicable
This is an old thread, but in case someone comes across it, the Route Map custom plugin does plot routes on maps https://appsource.microsoft.com/en-us/product/power-bi-visuals/WA104380985?tab=Overview
- ryanbaumannFrequent Visitor
This seems like a great fit for Mapbox GL tools as a custom viz. A few lines of javascript can easily transform point parts to arcs, and linestrings are natively rendered in Mapbox tools even for really large numbers of lines. - https://bl.ocks.org/ryanbaumann/7a5480c20f2de3aba91bb19435403b3b
- IainMacnabRegular Visitor
That looks like a lovely render. I will give that a try when I get a minute
Thanks for your reply
- v-chuncz-msftCommunity Support
You may follow the tutorial to create the custom visual. The developer tools can be used to build R Powered Custom Visual as well.
- IainMacnabRegular Visitor
- ryanbaumannFrequent Visitor
This seems like a great fit for a custom visual with Mapbox GL.
Here's an example of converting 1000 point pairs to arcs with a few lines of javascript for a custom visual - https://bl.ocks.org/ryanbaumann/7a5480c20f2de3aba91bb19435403b3b
- Julio7New Member
i was able to find a solution for this problem. i work for a large transportation company and we wanted to visualized our lanes by customer, states, timeframe etc... and ICON MAP PRO add in in power BI was able to help us with this need. it would be nice if microsoft could implement some of those visual and functions directly on the maps in power BI.