簡體   English   中英

在打印多個光柵leveplot R時打開x軸和y軸值

[英]Turn on x-axis and y-axis values when printing several rasters leveplot R

在以下示例中,我想打開x和y軸值(即,將空刻度標記為標簽):

library(rasterVis)
s <- stack(replicate(6, raster(matrix(runif(100), 10))))
levelplot(s, layout=c(3, 2), index.cond=list(c(1, 3, 5, 2, 4, 6)))

在實際數據中,我將使用lat和lon標記空的刻度線。

謝謝你的幫助。

library(rasterVis)
s <- stack(replicate(6, raster(matrix(runif(100), 10))))

x.scale <- list(font=10,
                fontface=2,
                alternating=1)

y.scale <- list(font=10,
                fontface=2,
                alternating=1)

levelplot(s, layout=c(3, 2), index.cond=list(c(1, 3, 5, 2, 4, 6)),
  scales = list(x=x.scale, y=y.scale))

在此處輸入圖片說明

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM