R/make.label.R

Defines functions make.label

make.label <-
function(cx, xnam, dimx, vx)
{
  if(cx == "random.bayesx")
    label <- paste("sx(", xnam, sep = "")
  if(cx == "sm.bayesx") {
    if(dimx > 1L)
      label <- paste("sx(", xnam[1L], ",", xnam[2L], sep = "")
    else
      label <- paste("sx(", xnam, sep = "")
  }
  if(cx == "mrf.bayesx")
    label <- paste("sx(", xnam, sep = "")
  if(cx == "geo.bayesx")
    label <- paste("sx(", xnam[1], sep = "")
  if(is.null(vx))
    label <- paste(label, ")", sep = "")
  else
    label <- paste(label, "):", vx, sep = "")

  return(label)
}

Try the R2BayesX package in your browser

Any scripts or data that you put into this service are public.

R2BayesX documentation built on Oct. 20, 2023, 3:01 p.m.