在Illustrator中将R的pch绘图设为“q”

11
每次我在R中使用lattice绘图时,如果使用pch=21参数,我的绘图在R绘图窗口和pdf文件中都正常绘制(圆圈带边框);然而当我在Adobe Illustrator或Inkscape中打开保存的pdf版本时,点被奇怪地转换为“q”。有人能解释一下这是为什么吗?这相当令人沮丧,因为我想在Illustrator或Inkscape中编辑我的绘图。

enter image description here


这个早期的问题可能会有用:https://dev59.com/1mkw5IYBdhLWcg3wSovA - bdemarest
2个回答

16

我认为您可能想要使用:

 useDingbats = FALSE 

如下所示:

pdf("myplot.pdf", useDingbats=FALSE)
plot()
dev.off()

9

?pdf has:

 On some systems the default plotting character ‘pch = 1’ is
 displayed in some PDF viewers incorrectly as a ‘"q"’ character.
 (These seem to be viewers based on the ‘poppler’ PDF rendering
 library).  This may be due to incorrect or incomplete mapping of
 font names to those used by the system.  Adding the following
 lines to ‘~/.fonts.conf’ or ‘/etc/fonts/local.conf’ may circumvent
 this problem.

 <fontconfig>    
 <alias binding="same">
   <family>ZapfDingbats</family>
   <accept><family>Dingbats</family></accept>
 </alias>
 </fontconfig>  

 Some further workarounds for problems with symbol fonts on viewers
 using ‘fontconfig’ are given in the ‘Cairo Fonts’ section of the
 help for ‘X11’.

那个fontconfig声明曾经在我的Linux机器上运行良好(现在仍然如此)。我建议你设置它或阅读引用句子中提到的其他页面,看看是否可以解决你遇到的问题。


网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接