- java.lang.Object
-
- net.finmath.plots.Plots
-
public class Plots extends Object
Static factory methods for various plots (used to keep demos short).- Author:
- Christian Fries
-
-
Constructor Summary
Constructors Constructor Description Plots()
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static Plot2DcreateDensity(List<Double> values, int numberOfPoints, double standardDeviations)static Plot2DcreateDensity(net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)static PlotcreateDensityBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations)Create a histogram behind a value scatter plot.static PlotcreateDensityBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations, Double xmin, Double xmax)static Plot2DcreateHistogram(List<Double> values, int numberOfPoints, double standardDeviations)static Plot2DcreateHistogram(net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)static PlotcreateHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations)Create a histogram behind a value scatter plot.static PlotcreateHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations, Double xmin, Double xmax)static Plot2DcreatePlotOfHistogram(net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)Deprecated, for removal: This API element is subject to removal in a future version.static PlotcreatePlotOfHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations)Deprecated, for removal: This API element is subject to removal in a future version.static PlotcreatePlotOfHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations, Double xmin, Double xmax)Deprecated, for removal: This API element is subject to removal in a future version.static Plot2DcreatePlotScatter(double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)Deprecated, for removal: This API element is subject to removal in a future version.static Plot2DcreatePlotScatter(List<Double> x, List<Double> y, double xmin, double xmax, int dotSize)Deprecated, for removal: This API element is subject to removal in a future version.static Plot2DcreatePlotScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax)Deprecated, for removal: This API element is subject to removal in a future version.static Plot2DcreatePlotScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax, int dotSize)Deprecated, for removal: This API element is subject to removal in a future version.static Plot2DcreateScatter(double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)static PlotcreateScatter(List<double[]> points, Double xmin, Double xmax, Double ymin, Double ymax, int dotSize)static Plot2DcreateScatter(List<Double> x, List<Double> y, double xmin, double xmax, int dotSize)static Plot2DcreateScatter(List<Double> x, Map<String,List<Double>> mapOfValues, double xmin, double xmax, int dotSize)Create a scatter plot.static Plot2DcreateScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y)static Plot2DcreateScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax)static Plot2DcreateScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax, int dotSize)static Plot2DupdateDensity(Plot2D histogram, List<Double> values, int numberOfPoints, double standardDeviations)static Plot2DupdateDensity(Plot2D histogram, net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)static Plot2DupdateHistogram(Plot2D histogram, List<Double> values, int numberOfPoints, double standardDeviations)static Plot2DupdateHistogram(Plot2D histogram, net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)static Plot2DupdatePlotOfHistogram(Plot2D histogram, net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)Deprecated, for removal: This API element is subject to removal in a future version.static Plot2DupdatePlotScatter(Plot2D plot, double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)Deprecated, for removal: This API element is subject to removal in a future version.static Plot2DupdatePlotScatter(Plot2D plot, List<Double> x, List<Double> y, double xmin, double xmax, int dotSize)static Plot2DupdateScatter(Plot2D plot, double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)
-
-
-
Method Detail
-
createScatter
public static Plot2D createScatter(List<Double> x, Map<String,List<Double>> mapOfValues, double xmin, double xmax, int dotSize)
Create a scatter plot.- Parameters:
x- List of x-values.mapOfValues- A map that maps a name to a list of y-values (which will be plotted (x,y) under that name.xmin- The min of the x-axis.xmax- The max of the x-axis.dotSize- The dot size.- Returns:
- The plot.
-
createScatter
public static Plot createScatter(List<double[]> points, Double xmin, Double xmax, Double ymin, Double ymax, int dotSize)
-
createScatter
public static Plot2D createScatter(double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)
-
createScatter
public static Plot2D createScatter(List<Double> x, List<Double> y, double xmin, double xmax, int dotSize)
-
updateScatter
public static Plot2D updateScatter(Plot2D plot, double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)
-
updatePlotScatter
public static Plot2D updatePlotScatter(Plot2D plot, List<Double> x, List<Double> y, double xmin, double xmax, int dotSize)
-
createScatter
public static Plot2D createScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax, int dotSize)
-
createScatter
public static Plot2D createScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax)
-
createScatter
public static Plot2D createScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y)
-
createHistogram
public static Plot2D createHistogram(net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)
-
createHistogram
public static Plot2D createHistogram(List<Double> values, int numberOfPoints, double standardDeviations)
-
updateHistogram
public static Plot2D updateHistogram(Plot2D histogram, net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)
-
updateHistogram
public static Plot2D updateHistogram(Plot2D histogram, List<Double> values, int numberOfPoints, double standardDeviations)
-
createHistogramBehindValues
public static Plot createHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations)
Create a histogram behind a value scatter plot.- Parameters:
randomVariableX- The random variable for the independent.randomVariableY- The random variable for the dependent.numberOfPoints- The number of bins to be used for the histogram.standardDeviations- The standard deviations to be covered by the independent.- Returns:
- The plot.
-
createHistogramBehindValues
public static Plot createHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations, Double xmin, Double xmax)
-
createDensity
public static Plot2D createDensity(net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)
-
createDensity
public static Plot2D createDensity(List<Double> values, int numberOfPoints, double standardDeviations)
-
updateDensity
public static Plot2D updateDensity(Plot2D histogram, net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)
-
updateDensity
public static Plot2D updateDensity(Plot2D histogram, List<Double> values, int numberOfPoints, double standardDeviations)
-
createDensityBehindValues
public static Plot createDensityBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations)
Create a histogram behind a value scatter plot.- Parameters:
randomVariableX- The random variable for the independent.randomVariableY- The random variable for the dependent.numberOfPoints- The number of bins to be used for the histogram.standardDeviations- The standard deviations to be covered by the independent.- Returns:
- The plot.
-
createDensityBehindValues
public static Plot createDensityBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations, Double xmin, Double xmax)
-
createPlotOfHistogram
@Deprecated(forRemoval=true) public static Plot2D createPlotOfHistogram(net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)
Deprecated, for removal: This API element is subject to removal in a future version.
-
updatePlotOfHistogram
@Deprecated(forRemoval=true) public static Plot2D updatePlotOfHistogram(Plot2D histogram, net.finmath.stochastic.RandomVariable randomVariable, int numberOfPoints, double standardDeviations)
Deprecated, for removal: This API element is subject to removal in a future version.
-
createPlotOfHistogramBehindValues
@Deprecated(forRemoval=true) public static Plot createPlotOfHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations)
Deprecated, for removal: This API element is subject to removal in a future version.
-
createPlotOfHistogramBehindValues
@Deprecated(forRemoval=true) public static Plot createPlotOfHistogramBehindValues(net.finmath.stochastic.RandomVariable randomVariableX, net.finmath.stochastic.RandomVariable randomVariableY, int numberOfPoints, double standardDeviations, Double xmin, Double xmax)
Deprecated, for removal: This API element is subject to removal in a future version.
-
createPlotScatter
@Deprecated(forRemoval=true) public static Plot2D createPlotScatter(double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)
Deprecated, for removal: This API element is subject to removal in a future version.
-
createPlotScatter
@Deprecated(forRemoval=true) public static Plot2D createPlotScatter(List<Double> x, List<Double> y, double xmin, double xmax, int dotSize)
Deprecated, for removal: This API element is subject to removal in a future version.
-
updatePlotScatter
@Deprecated(forRemoval=true) public static Plot2D updatePlotScatter(Plot2D plot, double[] xValues, double[] yValues, double xmin, double xmax, int dotSize)
Deprecated, for removal: This API element is subject to removal in a future version.
-
createPlotScatter
@Deprecated(forRemoval=true) public static Plot2D createPlotScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax, int dotSize)
Deprecated, for removal: This API element is subject to removal in a future version.
-
createPlotScatter
@Deprecated(forRemoval=true) public static Plot2D createPlotScatter(net.finmath.stochastic.RandomVariable x, net.finmath.stochastic.RandomVariable y, double xmin, double xmax)
Deprecated, for removal: This API element is subject to removal in a future version.
-
-