I want to create an atlas and the features to show are OUTSIDE the feature of the layer coverage.

The atlas feature 1 is Switzerland, but I want to show all embassy that are geographically OUTSIDE Switzerland, but that belongs to Switzerland, namely the Swiss embassy around the world. To show them I will create many maps and manually define the maps views. The same thing I will 2 with atlas feature 2 that is France and so on. To show them I need to create many different maps and pages for every atlas feature because every country (namely atlas feature) has different numbers of embassy and so on.

Switzeraland has x embassy around the world, French has y embassy and so on. So every atlas feature need different numbers of page or maps shape inside the page. My problem is that I don't know how to create an atlas with different number of pages and map shapes. It seems me that atlas can work only recurrent. If feature 1 has 3 page, feature 2 can have only 3 page, and feature 3 can have only 3 page. How can I have an atlas that change the page number for every atlas feature?

I add an example. You see an atlas with maps shape differents and in feature 1 you see the there are two page, in feature 2 there is 1 page. So, feature 1 has not the same layout of feature 2 (one vs two page and so on) enter image description here

Someone could ask me, why do yo need an atlas? I need an atlas because it helps me to automatically create a filter of the vector embassy that otherwise would have shown the embassy of the entire world. Feature 1 of the atlas that is Switzerland allows me with the filter in the symbology to see automatically only the Swiss embassy from the vector embassy and feature 2 only from France and so on. Atlas has only this purpose.

Pay attention: I don't work with embassy but I used only as example to show the concept in this thread.

  • Can you provide an example for your desired output? – Erik Jul 19 '20 at 12:44
  • I add an image above. – simone100 Jul 19 '20 at 13:05
  • Take care that I use the coverage layer only to have an automatic filter of the symbology of the layer embassy in the atlas. My coverage layer is "country.shp" and it shows the countries. Feature 1 of the atlas that represents Switzerland helps me to filter the symbology and display Swiss embassy, similar to gis.stackexchange.com/questions/173399/…. It happens because when the feature of the atlas is Switzerland the vector embassy applies a filter when the field country=Switzerland in embassy. – simone100 Jul 19 '20 at 13:52
  • For this reason if feature 1 was China that has 200 embassies around the world I would produce 200 maps and maybe 200 page. If feature 2 was Vatican City that has 10 embassies around the world I would produce 10 maps and maybe ten page. – simone100 Jul 19 '20 at 13:59
  • docs.qgis.org/3.4/en/docs/user_manual/print_composer/… And see "subsection" part. – Christophe P. Jul 20 '20 at 12:23

Provided your data has the right attributes, you would need to use a Report to accomplish this in QGIS. An Atlas will have the same exact layout for every feature in the atlas coverage layer, and while you can do a lot with it, it's not as dynamic as it sounds like you need.

You can think of reports almost as nested atlases, though they can be quite a lot more than that. For each feature in one layer, you can have it create a layout for each matching feature in a second layer. (Or a third, or fourth, etc.)

Here are a couple of scratch layers: country polygons and embassy points, each with a country attribute. I've symbolized both layers on said attribute to make this link clearer.

scratch layers

On the menu toolbar, choose File > New Report... Once you have your report window open, add a Field Group Section. With the new section selected, choose the countries layer, and countries field as well.

Create a second field group section below that, this time choosing embassies as the layer, and some identifier field. The report will automatically look for a matching country field in this sub-group layer.

atlas settings

For each field group in the atlas, you can check the box to Include body, being an atlas layout. So you could have a layout for each country, or skip it and go to the embassies directly, depending on what you need. Below is the first page of my report, showing a separate layout for the country itself, then for the first embassy.

sample output

If what you're really looking for is a unique layout design for each country/embassy, I'm afraid there's no simple way to generate that. The best you could hope for is perhaps a separate layer for each country, each of which could be its own Field Group in the report.

  • Thank you for the suggestion! I am trying to see how does it work with exercises! It works well, but at the moment I don't know how resolve an issue with a filter stackoverflow.com/questions/62995423/… – simone100 Jul 20 '20 at 12:47
  • Ah, yes. That's one thing missing from the reports which the Atlas does have. It might be a bit excessive, but you could always duplicate the countries layer and apply filters at the layer level, then add the duplicated layers as their own field groups. – JoshC Jul 20 '20 at 13:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.