plot.jointmotbf {MoTBFs}R Documentation

Bidimensional Plots for 'jointmotbf' Objects

Description

Draws the perpective and the contour plots for joint functions.

Usage

## S3 method for class 'jointmotbf'
plot(
  x,
  type = "contour",
  ranges = NULL,
  orientation = c(5, -30),
  data = NULL,
  filled = TRUE,
  ticktype = "simple",
  ...
)

Arguments

x

An object of class 'jointmotbf'.

type

A "character" string: by default it is "contour", the alternative one is "perspective".

ranges

A "numeric" matrix containing the domain of the variables by columns.

orientation

A "numeric" vector indicating the perpective of the plot in degrees. By default it is (5,-30).

ticktype

A "character" string: by default it is "simple" which draws just an arrow parallel to the axis to indicate direction of increase; "detailed" draws normal ticks.

data

A dataset of class "data.frame". Only two columns are allowed, it means two variables. It is only necessary to draw the points over the main plot. By defailt it is NULL.

filled

A logical argument; it is only used if type = "contour" is active; by default is TRUE so filled contours are plotted.

...

Further arguments to be passed as for plot.

Value

A plot of the joint function.

See Also

jointMoTBF

Examples

## 1 .EXAMPLE
## Dataset
X <- data.frame(rnorm(500), rnorm(500))

## Joint function
dim <- c(3,3) 
param1 <- parametersJointMoTBF(X, dimensions = dim)
P <- jointMoTBF(param1)
P

## Plots
plot(P)
plot(P, type = "perspective", orientation = c(90,0))

#############################################################################
## MORE EXAMPLES ############################################################
#############################################################################

## Dataset
X <- data.frame(rnorm(200,2), rexp(200, 1))

## Joint function
dim <- c(4,5)
param2 <- parametersJointMoTBF(X, dimensions = dim)
P <- jointMoTBF(param2)
P

## Plots
plot(P)
plot(P, filled = FALSE, data = X)
plot(P, type = "perspective", orientation = c(10,180))


[Package MoTBFs version 1.2 Index]