Setting size of the rgl device

左心房为你撑大大i 提交于 2019-12-04 05:10:26

Use par3d(windowRect = c(20, 30, 800, 800))

You can inspect the state of the RGL device with par3d. The "whitespace" is controlled by the "windowRect" values. There is an automatic increase in those values as the size of the display is increased;

> par3d("windowRect")
[1] 100 100 356 378
> par3d("windowRect")  # made the window have roughly 4 times the area
[1] 137   0 744 544

You can also specify what the corners of the windowRect will be.

?par3d

This should give you control that avoids both the "whitespace problem and the title overlap.

If you want to make the object larger in the viewing window, the rgl.viewpoint function can zoom. Smaller number make objects appear larger.

rgl.viewpoint(  zoom = .5 )

It was enough to set r3dDefaults:

r3dDefaults$windowRect <- c(0,50, 800, 800) 
plot3d(mdatapc, col=kmeanspc.cluster, size = 10)    
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!