On 03/20/2012 09:57 PM, Manuel Spínola wrote:
> Thank you Roman,
>
> I used ggsave, but the quality of the plot is not good. I got a "grid" all
> over the map and some of the background.
>
> Best,
>
> Manuel
>
> 2012/3/20 Roman LuÅ¡trik <roman.lustrik@gmail.com>
>
>> For lattice and ggplot2 graphics, you need to wrap the ggplot/qplot into a
>> print call. Or, you can use ggsave.
>>
>> Cheers,
>> Roman
>>
>>
>>
>> On Tue, Mar 20, 2012 at 10:41 PM, Manuel SpÃ­nola <mspinola10@gmail.com>wrote:
>>
>>> Dear list members,
>>>
>>> How can I save a map on pdf plotted with the functions levelplot or gplot
>>> from the rasterVis package without loosing quality of the map.
>>>
>>>> class(maparaster)
>>> [1] "RasterLayer"
>>> attr(,"package")
>>> [1] "raster"
>>>
>>>
>>> pdf("mp.pdf")
>>> levelplot(maparaster)
>>> dev.off()
>>>
>>> and
>>>
>>> pdf("mpgplot.pdf")
>>> gplot(maparaster) + geom_tile(aes(fill = value))
>>> dev.off()
>>>
>>>
>>> Best,
>>>
>>> Manuel
>>>
>>> --
>>> *Manuel SpÃ­nola, Ph.D.*
>>>
>>> Instituto Internacional en ConservaciÃ³n y Manejo de Vida Silvestre
>>> Universidad Nacional
>>> Apartado 1350-3000
>>> Heredia
>>> COSTA RICA
>>> mspinola@una.ac.cr
>>> mspinola10@gmail.com
>>> TelÃ©fono: (506) 2277-3598
>>> Fax: (506) 2237-7036
>>> Personal website: Lobito de rÃ­o <
>>> https://sites.google.com/site/lobitoderio/>
>>> Institutional website: ICOMVIS <http://www.icomvis.una.ac.cr/>
>>>
>>>        [[alternative HTML version deleted]]
>>>
>>>
>>> _______________________________________________
>>> R-sig-Geo mailing list
>>> R-sig-Geo@r-project.org
>>> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>>>
>>>
>>
>> --
>> In God we trust, all others bring data.
>>
>
>
>
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo@r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
Hi Manuel,

Please provide a small *reproducible* example that reproduces your
problem. In your situation, please also include a file with how the
figure looks on your computer. In addition, provide us with information
about your system, R version, and versions of the packages you are
using, sessionInfo() can do that for you.

cheers,
Paul

-- 
Paul Hiemstra, Ph.D.
Global Climate Division
Royal Netherlands Meteorological Institute (KNMI)
Wilhelminalaan 10 | 3732 GK | De Bilt | Kamer B 3.39
P.O. Box 201 | 3730 AE | De Bilt
tel: +31 30 2206 494

http://nl.linkedin.com/pub/paul-hiemstra/20/30b/770


	[[alternative HTML version deleted]]

