Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
通过使用函数 dbscan 如下:
ds <- dbscan(x, 0.2,showplot=1)
我们可以在每次迭代中看到集合图。不幸的是,有很多情节,所以在 R-Studio 中我只有最后 30 个。我怎样才能得到所有的情节?
如果我做:
jpeg("dbscans.jpeg") ds <- dbscan(x, 0.2,showplot=1) dev.off()
它当然行不通。
我认为这是因为您要输出到 jpeg。这对我有用:
library(fpc) pdf("dbscan.pdf") ds <- dbscan(mtcars[,c(1,2)],2,showplot=T) dev.off()
顺便说一句:你不需要分配dbscan(...)任何东西。这也有效:
dbscan(...)
library(fpc) pdf("dbscan.pdf") dbscan(mtcars[,c(1,2)],2,showplot=T) dev.off()