Forum Discussion

PaulDBrown's avatar
PaulDBrown
Community Champion
6 years ago
Solved

Importing TopoJSON file to create shape map: what Next?

Good morning,   I have succeeded in importing the following (extract) TopoJSON file to create a shape map: {"type":"Topology","objects":{"barris":{"type":"GeometryCollection","geometries":[{"type...
  • HotChilli's avatar
    HotChilli
    6 years ago

    Ignore the other thread that you mentioned.  You are trying to make this way too complicated.

     

    You do not need to know anything about TopoJSON to make this work.  Please re-read my previous answer (with the following additions/clarifications).

    You need two things to make shape map visualisations:

    1: A topoJSON file of the place/area/shape you are going to use.  If you are lucky, a nice person on the internet will already have made one that will work for your purposes.  It looks to me that you already have this because you have posted a picture of it rendering correctly on GitHub.  So you are halfway there (and all you had to do was search the web).

    2: Some data that relates to the shape you already have (in 1: above).  This is not extracted from the TopoJSON file.  It is the data that you want to connect to the shape file.  See my previous post's example of "Number of coffee shops in each barrio".  Your data will relate to barrios of Barcelona in some way but it will not come from editing the topojson. Remove this idea from your mind. 

     

    Get the data in 2: into your powerbi file.

    Drag a shapemap on to the report surface.

    Add a field to the Location field well.

    Use the "+ Add map" in the format section to link the shapefile in 1:

    Add another field to the Color Saturation field well.

    That's it.

    I highly recommend that you follow the instructions here