r - 阴谋无处

标签 r plot

我正在使用 limma 包的函数 plotMDS(),它通过 R 的简单 plot() 格式绘制图,并且还返回图上点的位置作为输出。我想使用 plotMDS() 的输出来制作我自己的美丽情节。

有什么方法可以运行 plotMDS() 而不真正生成它的绘图?我这样问的原因是我已经将输出转换为 PDF 文件并且我不希望 plotMDS() 的原始图在那里!

最佳答案

感谢@BenBolker,可以这样做:

pdf("Some file")
...
dev.new() # Putting new plots to nowhere
mds <- plotMDS(data)
dev.off() # Restoring new plots to the PDF file
plot(...) # Making the desired plot using mds
...
dev.off() # Closing PDF file

关于r - 阴谋无处,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13299263/

相关文章:

.net - 海量数据快速可视化的方法

r - R中按10分钟间隔对时间序列数据进行分组并求和

r - igraph:如何将图转换为二分图?

r - data.table 中的动态回归模型 -

matlab - 如何在 MATLAB 中使用不规则间隔的数据制作冲浪图?

r - R中两个变量的直方图

r - glmer 中的错误组件数量不正确

r - 如何在 R 中的循环中包含 GLM

r - 多核生成图

graphics - 数学冲刺 "Up and down"