Class Plot2DFX

  • All Implemented Interfaces:
    Plot

    public class Plot2DFX
    extends java.lang.Object
    implements Plot
    Small convenient wrapper for Java FX line plot.
    Author:
    Christian Fries
    • Constructor Summary

      Constructors 
      Constructor Description
      Plot2DFX()  
      Plot2DFX​(double xmin, double xmax, int numberOfPointsX, java.util.function.DoubleUnaryOperator function)  
      Plot2DFX​(double xmin, double xmax, int numberOfPointsX, java.util.List<Named<java.util.function.DoubleUnaryOperator>> doubleUnaryOperators)  
      Plot2DFX​(java.util.List<Plotable2D> plotables)  
    • Constructor Detail

      • Plot2DFX

        public Plot2DFX​(java.util.List<Plotable2D> plotables)
      • Plot2DFX

        public Plot2DFX​(double xmin,
                        double xmax,
                        int numberOfPointsX,
                        java.util.function.DoubleUnaryOperator function)
      • Plot2DFX

        public Plot2DFX​(double xmin,
                        double xmax,
                        int numberOfPointsX,
                        java.util.List<Named<java.util.function.DoubleUnaryOperator>> doubleUnaryOperators)
      • Plot2DFX

        public Plot2DFX()
    • Method Detail

      • show

        public void show()
        Specified by:
        show in interface Plot
      • get

        public javafx.scene.chart.Chart get()
      • saveAsJPG

        public void saveAsJPG​(java.io.File file,
                              int width,
                              int height)
                       throws java.io.IOException
        Specified by:
        saveAsJPG in interface Plot
        Throws:
        java.io.IOException
      • saveAsPNG

        public void saveAsPNG​(java.io.File file,
                              int width,
                              int height)
                       throws java.io.IOException
        Throws:
        java.io.IOException
      • saveAsPDF

        public void saveAsPDF​(java.io.File file,
                              int width,
                              int height)
                       throws java.io.IOException
        Specified by:
        saveAsPDF in interface Plot
        Throws:
        java.io.IOException
      • saveAsSVG

        public void saveAsSVG​(java.io.File file,
                              int width,
                              int height)
                       throws java.io.IOException
        Specified by:
        saveAsSVG in interface Plot
        Throws:
        java.io.IOException
      • setTitle

        public Plot2DFX setTitle​(java.lang.String title)
        Specified by:
        setTitle in interface Plot
      • setXAxisLabel

        public Plot2DFX setXAxisLabel​(java.lang.String xAxisLabel)
        Specified by:
        setXAxisLabel in interface Plot
      • setYAxisLabel

        public Plot2DFX setYAxisLabel​(java.lang.String yAxisLabel)
        Specified by:
        setYAxisLabel in interface Plot
      • setYAxisRange

        public Plot2DFX setYAxisRange​(java.lang.Double min,
                                      java.lang.Double max)
      • setZAxisLabel

        public Plot setZAxisLabel​(java.lang.String zAxisLabel)
        Specified by:
        setZAxisLabel in interface Plot
      • setIsLegendVisible

        public Plot setIsLegendVisible​(java.lang.Boolean isLegendVisible)
        Specified by:
        setIsLegendVisible in interface Plot
        Parameters:
        isLegendVisible - the isLegendVisible to set