Forum Discussion
Line shapefiles in Map visual + two data set
Hi guys,
I have two questions:
1. I want to show a map in Power BI that displays segments of a pipeline, therefore I am trying to import a line shapefile from QGIS but I cannot get it to work. I mean, I already did all the conversion process to TPJSON format, and imported it into power BI, but it shows a line without information, nor even a background map. I tried a different approach: I can get the coordinates at the start and end of each segment, but in the map visuals I can only use one set of coordinates (either start or end of the segment) and will show me just a point. The only way I can see a line is by using an Icon Map. Now, each segment has a deterioration value, I want to colour format the line to show the level of deterioration (i.e. if the segment is below 60% the line will show red, but if the segment is above 85% the line will show green ). Is it possible to do this?
2. In addition to the pipeline segments mentioned above, I want to add, in the same visual map, point data to show relevant locations in the pipeline. I also have the coordinates for that point, but how can I add it to the map? is there any method or visual tool I can use?
An example of the data that I have is as follows, where "up" means the coordinates of the segment start, and "down" means the coordinates of the segment end:
| Section | Up Lat | Up Long | Down Lat | Down Long | Deterioration |
| 1 | -23.3802 | 148.8272 | -23.3814 | 148.8283 | 60% |
| 2 | -23.3814 | 148.8283 | -23.3829 | 148.8292 | 75% |
| 3 | -23.3829 | 148.8292 | -23.3858 | 148.8304 | 81% |
| 4 | -23.3858 | 148.8304 | -23.3891 | 148.8317 | 90% |
| 5 | -23.3891 | 148.8317 | -23.3909 | 148.8323 | 79% |
| 6 | -23.3909 | 148.8323 | -23.3928 | 148.8331 | 81% |
| Point 1 | -23.3858 | 148.8304 |
Thank you very much for your help 🙂
3 Replies
- amitchandakSuper User
Anonymous , I am not very clear on that, try
https://dataveld.com/2016/09/12/topojson-map-files-for-power-bi-shape-map/
https://docs.microsoft.com/en-us/power-bi/visuals/desktop-shape-map
- Maritza_GCNew Member
Hello, you could provide me with an email to coordinate about the segments you worked on the maps, thank you.
Atte. Maritza (mail daniela80928 is gmail.com)
- some1elseHelper II
The ShapeMap only plots the topoJSON you provide, without any base layer.
I think you are in the same spot I was a few months ago and I would try IconMap visual.
Since you already use QGIS, you can convert each segment coordinates to a CSV file and then make a LINESTRING combining the segments that belong to a specific ID. After importing to IconMap, you can then write a measure to conditional format each line, based on the level of detioration.
Pay attention that custom visuals only allow for 30k entries to be shown at same time. I solved this by groupping by zones.