Forum Discussion
GeoJSON reference layer - location labels/names
Hi
New to mapping in PBI... I've got a GEOJSON file I'm overlaying on top of some "other" school location data. The GEOJSON file has our "home" schools in and it shows as red dots fine, but how do I get the name of home schools in the GEOJSON file to show? As tooltips or something? Importing to MapShaper and it's recognising the name / number of students etc fine.
Don't believe we can use th ArcGIS visual, just yet. Thought the reference layer should do this?
Cheers
Keith
Make sure you don't strip out the polygon attributes when exporting to TopoJSON in MapShaper.
- Anonymous3 years agoNot applicable
Thanks for the reply! Ok, several questions...
For the fictious locations, I want 2 points (Lat / Lon / name changed etc) and I have this as GeoJSON and TopoJSON (seems to be little difference? and isn't a polygon, points are fine / basic)
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"properties": {
"color": "Red",
"name": "LBR1"
},
"geometry": {
"coordinates": [
-0.087724,
51.507904
],
"type": "Point"
},
"id": 0
},
{
"type": "Feature",
"properties": {
"color": "Red",
"name": "LBR2"
},
"geometry": {
"coordinates": [
-0.087724,
51.507904
],
"type": "Point"
},
"id": 1
}
]
}As far as I understand it, I can drop this in as a reference layer and this works showing 2 red dots, but how would I get the name to show (all the time / on hover) or something? Unless I'm missing the point of reference layers... I'd basically like a layer where nothing changes (Home layer) and then dynamic data I can slice 'n' dice. Thoughts welcomed! Cheers Keith
- lbendlin3 years agoSuper User
Have a "name" field in your data model that carries the values in your "name" property. Declare that field as a geo place.
- Anonymous3 years agoNot applicable
Hi
Thanks for getting back to me.
Ok, so the very simple model is :
And I drop postcode onto an Azure map to show postcodes. Works a treat. I then have the GeoJSON file mentioned earlier. Unsure where the 'name' field should be going? Do I create a a tabel with 2 values in LBR1 / LBR2 and the column is called name? Apologies if I sound dumb... And thanks for your help!
Cheers