2

I am mapping the distribution of 325 bird species, displaying circles in the grid cells each species occurs in. The data contains as many duplicates of the NAME as there are cells in which it occurs. I produce a map by filtering for a NAME then want to print the maps using the NAME field in a label as a caption below the map. I would like to have it generated automatically rather than write it in manually - in anticipation of being able to generate all species maps as an Atlas (that's another issue).

So far, all I get by using [% name %] is [name], not the species name. Any ideas of what I might be missing? Nothing I've found by searching has helped so far.

3

[% name %] will only be evaluated when at print time when printing using the Atlas option.

It will be shown as [name] until you print.

6
  • Thanks for that. The print copies also had the [name] error. I just tried again by adding a new name-only shapefile and using that as the Coverage Layer, and it worked fine for the name. Problem is, then it prints the Atlas maps with the names but keeps the map the same. Back to the drawing board.
    – user23486
    Nov 7 '13 at 6:20
  • Do you have a name field in your grid coverage layer. Can you post a picture of your atlas panel and the attribute table.
    – Nathan W
    Nov 7 '13 at 6:24
  • I have a NAME field in the main layer, but because there are 1000s of records, the Atlas tries to print them all (I had to abort an attempt at it earlier). When I filter in the main QGIS window it compiles all the records for a species onto the map, but I can't figure out how to use a filter for the Atlas. Filtering on the name in the Atlas window only does the first species. Not sure how to post images - today was my first post.
    – user23486
    Nov 7 '13 at 8:28
  • Unfortunatly, the Atlas filtering only works for generating maps in different locations with the same content, not the same location with different content.
    – Bernd V.
    Dec 21 '14 at 17:14
  • 3
    @BerndV. That's not strictly true - you can definitely use an Atlas for a static map location but varying content. Use a rule based (or data defined) symbology and take advantage of the "attribute( $atlasfeature, 'field_name' )" expression function.
    – ndawson
    Apr 27 '15 at 5:37

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.