riatelab / mapsf

Thematic cartography with R
https://riatelab.github.io/mapsf/
GNU General Public License v3.0
224 stars 24 forks source link

Unable to change position of credits #64

Closed asitemade4u closed 8 months ago

asitemade4u commented 8 months ago

Hi, I am drawing a map using mapsf and I have an issue with mf_credits only: whatever the parameter I pass to pos(center, rightbottom, bottomright), I cannot get the credits aligned to another position than bottom-left.

Here is my code:

mapsf::mf_credits(glue::glue("By Census Tracts, {clsnam}\nSource: IPUMS. 2023. http://doi.org/10.18128/D050.V18.0", cex = 0.7, pos = "bottomright", col = "#000000"))

And here is the result I get:

1920-ger (2)

Am I missing something? Thanks, S.

rCarto commented 8 months ago

I see:

library(mapsf)
mtq <- mf_get_mtq()
mf_map(mtq)
mf_credits(txt = "pos = bottomright", pos = "bottomright")
mf_credits(txt = "pos = bottomleft", pos = "bottomleft")
mf_credits(txt = "    pos = rightbottom", pos = "rightbottom")

Created on 2024-02-20 with reprex v2.1.0

Can you provide a reproducible example (available data & code, no extra packages)?

rCarto commented 8 months ago

your parentheses are in the wrong place

asitemade4u commented 8 months ago

Oh yes, sorry for bothering, my bad...