smile.plot
Class Surface
- java.lang.Object
-
- smile.plot.Shape
-
- smile.plot.Plot
-
- smile.plot.Surface
-
public class Surface extends Plot
A surface object gives 3D information e.g. a contour plots.
-
-
Constructor Summary
Constructors Constructor and Description Surface(double[][] z)Constructor.Surface(double[][][] data)Constructor for irregular mesh grid.Surface(double[][][] data, java.awt.Color[] palette)Constructor for irregular mesh grid.Surface(double[][] z, java.awt.Color[] palette)Constructor.Surface(double[] x, double[] y, double[][] z)Constructor for regular mesh grid.Surface(double[] x, double[] y, double[][] z, java.awt.Color[] palette)Constructor for regular mesh grid.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidpaint(Graphics g)Draw the component with given graphics object.static PlotCanvasplot(double[][] z)Create a plot canvas with the 3D surface plot of given data.static PlotCanvasplot(double[][][] data)Create a plot canvas with the 3D surface plot of given data.static PlotCanvasplot(double[][][] data, java.awt.Color[] palette)Create a plot canvas with the 3D surface plot of given data.static PlotCanvasplot(double[][] z, java.awt.Color[] palette)Create a plot canvas with the 3D surface plot of given data.static PlotCanvasplot(double[] x, double[] y, double[][] z)Create a plot canvas with the 3D surface plot of given data.static PlotCanvasplot(double[] x, double[] y, double[][] z, java.awt.Color[] palette)Create a plot canvas with the 3D surface plot of given data.-
Methods inherited from class smile.plot.Plot
getID, getToolBar, getToolTip, setID
-
-
-
-
Constructor Detail
-
Surface
public Surface(double[][] z)
Constructor.- Parameters:
z- the z-axis values of surface. The x-axis and y-axis location of surface will be set to 0.5, 1.5, 2.5, ...
-
Surface
public Surface(double[][] z, java.awt.Color[] palette)Constructor.- Parameters:
z- the z-axis values of surface. The x-axis and y-axis location of surface will be set to 0.5, 1.5, 2.5, ...palette- the color palette.
-
Surface
public Surface(double[] x, double[] y, double[][] z)Constructor for regular mesh grid.- Parameters:
x- the x-axis values of surface.y- the y-axis values of surface.z- the z-axis values of surface.
-
Surface
public Surface(double[] x, double[] y, double[][] z, java.awt.Color[] palette)Constructor for regular mesh grid.- Parameters:
x- the x-axis values of surface.y- the y-axis values of surface.z- the z-axis values of surface.palette- the color palette.
-
Surface
public Surface(double[][][] data)
Constructor for irregular mesh grid.- Parameters:
data- an m x n x 3 array which are coordinates of m x n surface.
-
Surface
public Surface(double[][][] data, java.awt.Color[] palette)Constructor for irregular mesh grid.- Parameters:
data- an m x n x 3 array which are coordinates of m x n surface.
-
-
Method Detail
-
paint
public void paint(Graphics g)
Description copied from class:ShapeDraw the component with given graphics object.
-
plot
public static PlotCanvas plot(double[][] z)
Create a plot canvas with the 3D surface plot of given data.- Parameters:
z- the z-axis values of surface. The x-axis and y-axis location of surface will be set to 0.5, 1.5, 2.5, ...
-
plot
public static PlotCanvas plot(double[][] z, java.awt.Color[] palette)
Create a plot canvas with the 3D surface plot of given data.- Parameters:
z- the z-axis values of surface. The x-axis and y-axis location of surface will be set to 0.5, 1.5, 2.5, ...palette- the color palette.
-
plot
public static PlotCanvas plot(double[] x, double[] y, double[][] z)
Create a plot canvas with the 3D surface plot of given data.- Parameters:
x- the x-axis values of surface.y- the y-axis values of surface.z- the z-axis values of surface.
-
plot
public static PlotCanvas plot(double[] x, double[] y, double[][] z, java.awt.Color[] palette)
Create a plot canvas with the 3D surface plot of given data.- Parameters:
x- the x-axis values of surface.y- the y-axis values of surface.z- the z-axis values of surface.palette- the color palette.
-
plot
public static PlotCanvas plot(double[][][] data)
Create a plot canvas with the 3D surface plot of given data.- Parameters:
data- an m x n x 3 array which are coordinates of m x n surface.
-
plot
public static PlotCanvas plot(double[][][] data, java.awt.Color[] palette)
Create a plot canvas with the 3D surface plot of given data.- Parameters:
data- an m x n x 3 array which are coordinates of m x n surface.palette- the color palette.
-
-
DataMelt 3.0 © DataMelt by jWork.ORG