Class DistributionPlotExtendedData<G extends GtuData,Z extends Number>

Type Parameters:
G - GTU data type that needs to be consistent between the sampler data and the extended data type
Z - value type that needs to be consistent between extended data type and label data
All Implemented Interfaces:
Identifiable, org.jfree.data.general.Dataset, org.jfree.data.general.SeriesDataset, org.jfree.data.xy.IntervalXYDataset, org.jfree.data.xy.XYDataset

public class DistributionPlotExtendedData<G extends GtuData,Z extends Number> extends AbstractPlot<DistributionPlotExtendedData.DistributionPaintState> implements org.jfree.data.xy.IntervalXYDataset
Distribution data plot for any numerical extended trajectory data. Data is collected cumulatively; each interval adds to the totals of the previous interval.

Copyright (c) 2026-2026 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved.
BSD-style license. See OpenTrafficSim License.

Author:
Wouter Schakel
  • Constructor Details

  • Method Details

    • getSeriesCount

      public int getSeriesCount()
      Specified by:
      getSeriesCount in interface org.jfree.data.general.SeriesDataset
    • getSeriesKey

      public Comparable getSeriesKey(int series)
      Specified by:
      getSeriesKey in interface org.jfree.data.general.SeriesDataset
    • indexOf

      public int indexOf(Comparable seriesKey)
      Specified by:
      indexOf in interface org.jfree.data.general.SeriesDataset
    • getDomainOrder

      public org.jfree.data.DomainOrder getDomainOrder()
      Specified by:
      getDomainOrder in interface org.jfree.data.xy.XYDataset
    • getItemCount

      public int getItemCount(int series)
      Specified by:
      getItemCount in interface org.jfree.data.xy.XYDataset
    • getX

      public Number getX(int series, int item)
      Specified by:
      getX in interface org.jfree.data.xy.XYDataset
    • getXValue

      public double getXValue(int series, int item)
      Specified by:
      getXValue in interface org.jfree.data.xy.XYDataset
    • getY

      public Number getY(int series, int item)
      Specified by:
      getY in interface org.jfree.data.xy.XYDataset
    • getYValue

      public double getYValue(int series, int item)
      Specified by:
      getYValue in interface org.jfree.data.xy.XYDataset
    • getStartX

      public Number getStartX(int series, int item)
      Specified by:
      getStartX in interface org.jfree.data.xy.IntervalXYDataset
    • getStartXValue

      public double getStartXValue(int series, int item)
      Specified by:
      getStartXValue in interface org.jfree.data.xy.IntervalXYDataset
    • getEndX

      public Number getEndX(int series, int item)
      Specified by:
      getEndX in interface org.jfree.data.xy.IntervalXYDataset
    • getEndXValue

      public double getEndXValue(int series, int item)
      Specified by:
      getEndXValue in interface org.jfree.data.xy.IntervalXYDataset
    • getStartY

      public Number getStartY(int series, int item)
      Specified by:
      getStartY in interface org.jfree.data.xy.IntervalXYDataset
    • getStartYValue

      public double getStartYValue(int series, int item)
      Specified by:
      getStartYValue in interface org.jfree.data.xy.IntervalXYDataset
    • getEndY

      public Number getEndY(int series, int item)
      Specified by:
      getEndY in interface org.jfree.data.xy.IntervalXYDataset
    • getEndYValue

      public double getEndYValue(int series, int item)
      Specified by:
      getEndYValue in interface org.jfree.data.xy.IntervalXYDataset
    • getGraphType

      public GraphType getGraphType()
      Description copied from class: AbstractPlot
      Return the graph type for transceiver.
      Specified by:
      getGraphType in class AbstractPlot<DistributionPlotExtendedData.DistributionPaintState>
      Returns:
      the graph type.
    • getStatusLabel

      public String getStatusLabel(double domainValue, double rangeValue)
      Description copied from class: AbstractPlot
      Returns the status label when the mouse is over the given location.
      Specified by:
      getStatusLabel in class AbstractPlot<DistributionPlotExtendedData.DistributionPaintState>
      Parameters:
      domainValue - domain value (x-axis)
      rangeValue - range value (y-axis)
      Returns:
      status label when the mouse is over the given location
    • emptyPaintState

      Description copied from class: AbstractPlot
      Returns an empty paint state. This is used at plot initialization.
      Specified by:
      emptyPaintState in class AbstractPlot<DistributionPlotExtendedData.DistributionPaintState>
      Returns:
      empty paint state.
    • calculatePaintState

      protected void calculatePaintState(org.djunits.value.vdouble.scalar.Duration time)
      Description copied from class: AbstractPlot
      Calculates the paint state object and offers it through AbstractPlot.offerPaintState(S), or delegates this work to a delegate. This method is invoked by the worker thread and can thus perform heavy calculations outside of the Swing EDT. Intermediate paint states during long calculations may also be offered. It is up to the implementation to either calculate a complete paint state, or cumulatively built on the results from previous calls. It is also up to the implementation to know when the whole time span needs to be recalculated due to property changes.
      Specified by:
      calculatePaintState in class AbstractPlot<DistributionPlotExtendedData.DistributionPaintState>
      Parameters:
      time - time until which data in the paint state should be calculated
    • setAutoBoundDomain

      public void setAutoBoundDomain(org.jfree.chart.plot.XYPlot plot)
      Description copied from class: AbstractPlot
      Overridable; activates auto bounds on domain axis from user input. This class does not force the use of XYPlots, but the auto bounds command comes from the ChartPanel that shows this plot. In case the used plot is a XYPlot, this method is then invoked. Sub classes with auto domain bounds that work with an XYPlot should implement this. The method is not abstract as the use of XYPlot is not obligated.
      Overrides:
      setAutoBoundDomain in class AbstractPlot<DistributionPlotExtendedData.DistributionPaintState>
      Parameters:
      plot - plot
    • setAutoBoundRange

      public void setAutoBoundRange(org.jfree.chart.plot.XYPlot plot)
      Description copied from class: AbstractPlot
      Overridable; activates auto bounds on range axis from user input. This class does not force the use of XYPlots, but the auto bounds command comes from the ChartPanel that shows this plot. In case the used plot is a XYPlot, this method is then invoked. Sub classes with auto range bounds that work with an XYPlot should implement this. The method is not abstract as the use of XYPlot is not obligated.
      Overrides:
      setAutoBoundRange in class AbstractPlot<DistributionPlotExtendedData.DistributionPaintState>
      Parameters:
      plot - plot