File: ImageOcean.R

package info (click to toggle)
r-cran-plot3d 1.4.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,588 kB
  • sloc: makefile: 2
file content (20 lines) | stat: -rw-r--r-- 630 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
## =============================================================================
## Plot Ocean bathymetry
## =============================================================================

ImageOcean <- function(...) {
  dots <- list(...)
  if (is.null(dots$xlab)) 
    dots$xlab  <- "longitude"
  if (is.null(dots$ylab)) 
    dots$ylab  <- "latitude"
  if (is.null(dots$clab)) 
    dots$clab  <- "depth, m"
  if (is.null(dots$NAcol)) 
    dots$NAcol  <- "black"
  HH <- get("Hypsometry") # import package data set from /data  
  zz       <- HH$z
  zz[zz>0] <- NA   
  do.call("image2D", c(alist(zz, x = HH$x, y = HH$y), dots))
}