Class StaircasePlot
java.lang.Object
smile.plot.swing.Shape
smile.plot.swing.Plot
smile.plot.swing.StaircasePlot
Staircase plot is a special case of line which is most useful to display
empirical distribution.
-
Constructor Summary
ConstructorsConstructorDescriptionStaircasePlot(Staircase... lines) Constructor.StaircasePlot(Staircase[] lines, Legend[] legends) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionfigure()Returns a figure containing the plot.double[]Returns the lower bound of data.double[]Returns the upper bound of data.legends()Returns the optional legend of shape.static StaircasePlotof(double[][] data) Creates a line plot.static StaircasePlotCreates a line plot.voidDraws the shape.
-
Constructor Details
-
StaircasePlot
-
StaircasePlot
-
-
Method Details
-
legends
-
figure
-
getLowerBound
public double[] getLowerBound()Description copied from class:PlotReturns the lower bound of data.- Specified by:
getLowerBoundin classPlot- Returns:
- the lower bound of data.
-
getUpperBound
public double[] getUpperBound()Description copied from class:PlotReturns the upper bound of data.- Specified by:
getUpperBoundin classPlot- Returns:
- the upper bound of data.
-
paint
-
of
Creates a line plot.- Parameters:
data- the point coordinates.- Returns:
- the plot.
-
of
Creates a line plot.- Parameters:
data- the point coordinates.color- the line color.label- the legend label.- Returns:
- the plot.
-