Learn R Programming

ads (version 1.5-5)

plot.fads: Plot second-order neighbourhood functions

Description

Plot second-order neighbourhood function estimates returned by functions kfun, k12fun, kmfun, kijfun or ki.fun.

Usage

# S3 method for fads
plot(x, opt, cols, lty, main, sub, legend, csize, …)

Arguments

x

an object of class "fads" (see Details).

opt

one of c("all","L","K","n","g") to display either all or one of the functions in a single window. By default opt = "all" for fads objects of subclass "kfun", "k12fun", or "kmfun"; by default opt = "L" for fads objects of subclass "kij", or "ki.".

cols

(optional) colours used for plotting functions.

lty

(optional) line types used for plotting functions.

main

by default, the value of argument x, otherwise a text to be displayed as a title of the plot. main=NULL displays no title.

sub

by default, the name of the function displayed, otherwise a text to be displayed as function subtitle. sub=NULL displays no subtitle.

legend

If legend = TRUE (the default) a legend for the plotting functions is displayed.

csize

scaling factor for font size so that actual font size is par("cex")*csize. By default csize = 1.

extra arguments that will be passed to the plotting functions plot.swin, plot.default, symbols and/or points.

Value

none.

Details

Function plot.fads displays second-order neighbourhood function estimates as a function of interpoint distance, with expected values as well as confidence interval limits when computed. Argument x can be any fads object returned by functions kfun, k12fun, kmfun, kijfun or ki.fun.

See Also

kfun, k12fun, kmfun, kijfun, ki.fun.

Examples

Run this code
# NOT RUN {
  data(BPoirier)
  BP <- BPoirier
  
# }
# NOT RUN {
Ripley's function
# }
# NOT RUN {
  swr <- spp(BP$trees, win=BP$rect)
  k.swr <- kfun(swr, 25, 1, 500)
  plot(k.swr)
  
  
# }
# NOT RUN {
Intertype function
# }
# NOT RUN {
  swrm <- spp(BP$trees, win=BP$rect, marks=BP$species)
  k12.swrm <- k12fun(swrm, 25, 1, 500, marks=c("beech","oak"))
  plot(k12.swrm, opt="L", cols=1)
  
  
# }
# NOT RUN {
Mark correlation function
# }
# NOT RUN {
  swrm <- spp(BP$trees, win=BP$rect, marks=BP$dbh)
  km.swrm <- kmfun(swrm, 25, 1, 500)
  plot(km.swrm, main="Example 1", sub=NULL, legend=FALSE)

# }

Run the code above in your browser using DataLab