3D plot of two-dimensional correlation spectra.

Share:

Description

plot_corr2din3d plots two-dimensional correlation spectra as an 3D surface.

Usage

1
2
3
4
plot_corr2din3d(Mat, specx = NULL, specy = NULL, scalex = NULL,
  scaley = NULL, Col = colorspace::diverge_hcl(64, h = c(240, 0), c = 100, l
  = c(20, 100), power = 0.4), reduce = NULL, zlim = NULL,
  projection = FALSE, ...)

Arguments

Mat

Real numeric matrix containing the z-values to plot.

specx, specy

Numeric vector containing the data, that will be plotted at the x and y axis. Can be any data and does not need to have the same dimensions as Mat.

scalex, scaley

A real number which describes how specx (or specy) get scaled. Positive numbers lead to a spectrum plotted inside the box, while negative numbers lead to a spectrum plotted outside the box.

Col

Vector containing colors used to plot the 3D plot and the respective projection.

reduce

Non-zero rational number describing how to resample the data values. Can reduce the computational demand and can be used for fast previews.

zlim

Numeric vector with two values indicating the z-range of the 3D plot.

projection

Logical: Should a 2D projection of the 3D surface be plotted a the bottom of the box?

...

Additional arguments passed to drape.plot.

Details

For the synchronous correlation spectrum the real component (Re) of the complex correlation matrix must be plotted. The asynchronous spectrum is the respective imaginary component (Im).

See Also

See plot_corr2d for 2D plots. See drape.plot for information on the plot function.

Examples

1
2
3
4
5
6
7
8
9
   data(FuranMale, package = "corr2D")
   twod <- corr2d(FuranMale, Ref1 = FuranMale[1, ], corenumber = 1)
   
   plot_corr2din3d(Mat = Re(twod$FT), specx = twod$Ref1,
       specy = twod$Ref1, reduce = 2, scalex = -175, scaley = -175,
       zlim = c(-1.5, 2.2)*10^-3, projection = FALSE,
       border = gray(0.2), theta = 25, phi = 15, add.legend = FALSE,
       Col = fields::tim.colors(64))