在绘制栅格时将par()设置更改为默认值

时间:2015-04-30 22:05:10

标签: r plot raster par

运行以下代码时,R将返回下面的图像。

我应该如何更改par()设置(如下所示),以便返回单张图片?我认为这是因为我手动更改了par()设置。有没有办法将par()设置为默认设置,,因为我不知道我的默认设置

library(raster)
r1 <- brick(system.file("external/rlogo.grd", package="raster"))
plotRGB(r1)
plot(r1, xlim=c(0, 50), ylim=c(0, 50))


> par()
$xlog
[1] FALSE

$ylog
[1] FALSE

$adj
[1] 0.5

$ann
[1] TRUE

$ask
[1] FALSE

$bg
[1] "white"

$bty
[1] "o"

$cex
[1] 1

$cex.axis
[1] 1

$cex.lab
[1] 1

$cex.main
[1] 1.2

$cex.sub
[1] 1

$cin
[1] 0.2000000 0.2666667

$col
[1] "black"

$col.axis
[1] "black"

$col.lab
[1] "black"

$col.main
[1] "black"

$col.sub
[1] "black"

$cra
[1] 14.4 19.2

$crt
[1] 0

$csi
[1] 0.2666667

$cxy
[1] 3.659406 4.879208

$din
[1] 9.000000 4.208333

$err
[1] 0

$family
[1] ""

$fg
[1] "black"

$fig
[1] 0 1 0 1

$fin
[1] 9.000000 4.208333

$font
[1] 1

$font.axis
[1] 1

$font.lab
[1] 1

$font.main
[1] 2

$font.sub
[1] 1

$lab
[1] 5 5 7

$las
[1] 0

$lend
[1] "round"

$lheight
[1] 1

$ljoin
[1] "round"

$lmitre
[1] 10

$lty
[1] "solid"

$lwd
[1] 1

$mai
[1] 1.360000 1.093333 1.093333 0.560000

$mar
[1] 5.1 4.1 4.1 2.1

$mex
[1] 1

$mfcol
[1] 1 1

$mfg
[1] 1 1 1 1

$mfrow
[1] 1 1

$mgp
[1] 3 1 0

$mkh
[1] 0.001

$new
[1] FALSE

$oma
[1] 0 0 0 0

$omd
[1] 0 1 0 1

$omi
[1] 0 0 0 0

$page
[1] TRUE

$pch
[1] 1

$pin
[1] 9.000000 4.208333

$plt
[1] 0 1 0 1

$ps
[1] 16

$pty
[1] "m"

$smo
[1] 1

$srt
[1] 0

$tck
[1] NA

$tcl
[1] -0.5

$usr
[1] -31.83663 132.83663   0.00000  77.00000

$xaxp
[1]   0 100   2

$xaxs
[1] "r"

$xaxt
[1] "s"

$xpd
[1] FALSE

$yaxp
[1]  0 70  7

$yaxs
[1] "r"

$yaxt
[1] "s"

$ylbias
[1] 0.2

enter image description here

0 个答案:

没有答案