[R-sig-Geo] Fwd: Pie charts on a map. v2

Jue Lin-Ye jl.iccp at gmail.com
Sun Apr 12 18:29:54 CEST 2015


​Thank you so much for answering! I have checked the two points that you
have mentioned. I actually had library(rworldxtra) in my original, longer
code, so I have copied it to this shorter one. However, R still refuses to
plot anything on the map.

About point 2, I am focusing on the Catalan coast with
xlim=c(.5,3.5),ylim=c(40.5,42.42)

​and it seems that there is no option for "NE Spain", "Catalonia" or
anything of the kind.

I enclose the modified code herein.

Best regards,

Jue​

On 12 April 2015 at 18:15, Baldwin, Jim -FS <jbaldwin at fs.fed.us> wrote:

> I think there are two issues:
>
> 1. You need the rworldxtra package to get the countriesHigh dataset so
> adding in
>     library(rworldxtra) is necessary.
> 2. I think you need to "focus" the figure to a smaller area and add in a
> statement
>     like mapRegion="Somalia" in the mapPies function.
>
> Jim
>
>
> From: R-sig-Geo [mailto:r-sig-geo-bounces at r-project.org] On Behalf Of Jue
> Lin-Ye
> Sent: Sunday, April 12, 2015 8:40 AM
> To: r-sig-geo at r-project.org
> Subject: [R-sig-Geo] Fwd: Pie charts on a map. v2
>
>> Dear sirs/madams,
>
> May someone please help me with this issue: I have been trying to plot pie
> charts on a map, without much success (see code enclosed herein). This is
> quite distressing to me, as I had plot the same kind of map before without
> problems. It would be appreciated if anyone would point out the flaw. I
> enclose a reproducible set of data and codes for you to work with. I have
> tested the code, you just have to paste the three of the files in the same
> folder.
>
> Thank you very much in advance.
>>
> --
> Jue
>
>> ​ P.S.: My e-mails asking for questions are sometimes quite short and can
> seem rude, I am sorry for that. The truth is that I hearfully appreciate
> any help of yours. ​
>>
>


-- 
Jue
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20150412/ffe5a752/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Piecharts.R
Type: text/x-r-source
Size: 557 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20150412/ffe5a752/attachment.bin>


More information about the R-sig-Geo mailing list