R/pstext.R

Defines functions pstext

Documented in pstext

pstext <- function(x, cmd="-J -R -O -K", file=getOption("gmt.file"))
{
  if(is.null(file))
    stop("please pass a valid 'file' argument, or run gmt(file=\"myfile\")")
  owd <- setwd(dirname(file)); on.exit(setwd(owd))

  tmp <- paste(dirname(tempdir()), "text.gmt", sep="/")
  r2gmt(x, tmp)
  gmt.system(paste("gmt pstext",tmp,cmd), file=file, append=TRUE)

  invisible(NULL)
}
arnima-github/gmt documentation built on April 21, 2023, 7:12 p.m.