Package hec.chart

Class HistogramChart

All Implemented Interfaces:
ActionListener, MouseListener, MouseMotionListener, ImageObserver, MenuContainer, Printable, Serializable, EventListener, Accessible, org.jfree.chart.event.ChartChangeListener, org.jfree.chart.event.ChartProgressListener, org.jfree.chart.event.OverlayChangeListener

public class HistogramChart extends org.jfree.chart.ChartPanel
Copyright (C) 2014 Hydrologic Engineering Center, United States Army Corps of Engineers, All Rights Reserved HEC-Java NEXGEN Version 1.0beta
See Also:
  • Field Details

    • COUNTS

      public static final int COUNTS
      See Also:
    • FREQUENCIES

      public static final int FREQUENCIES
      See Also:
    • NUMBER_OF_BINS

      public static final int NUMBER_OF_BINS
      See Also:
    • BIN_SIZE

      public static final int BIN_SIZE
      See Also:
    • USER_DEFINED

      public static final int USER_DEFINED
      See Also:
    • nBinsDefault

      public static final int nBinsDefault
      See Also:
    • binSizeDefault

      public static final double binSizeDefault
      See Also:
    • _chart

      protected org.jfree.chart.JFreeChart _chart
    • _values

      protected double[] _values
    • _nbins

      protected int _nbins
    • _binSize

      protected double _binSize
    • _xMin

      protected double _xMin
    • _xMax

      protected double _xMax
    • _histogramType

      protected int _histogramType
    • _binType

      protected int _binType
    • _hist

      protected Histogram _hist
    • _cp

      protected org.jfree.chart.ChartPanel _cp
    • _dataName

      protected String _dataName
    • _xLabel

      protected String _xLabel
    • _yLabel

      protected String _yLabel
    • _histTitle

      protected String _histTitle
    • _plotAnalytic

      protected boolean _plotAnalytic
    • _containers

      protected List<? extends DataContainer> _containers
    • _histTool

      protected HistogramPlotDialog _histTool
    • _curve

      protected int _curve
  • Constructor Details

    • HistogramChart

      public HistogramChart()
    • HistogramChart

      public HistogramChart(Histogram hist, int histType, int binType)
    • HistogramChart

      public HistogramChart(List<? extends DataContainer> pdContainers, int histType, int binType)
      Parameters:
      pdContainers - Paired data containers
      histType - one of COUNTS or FREQUENCIES
      binType - one of NUMBER_OF_BINS or BIN_SIZE
  • Method Details

    • init

      public void init(List<? extends DataContainer> pdcList, int histType, int binType)
    • init

      public void init(List<? extends DataContainer> pdcList, int histType, int binType, int curve)
    • init

      public void init(List<? extends DataContainer> containers, int histType, int binType, String xAxisPlotLabels)
      Parameters:
      containers - Paired data containers
      histType - one of COUNTS or FREQUENCIES
      binType - one of NUMBER_OF_BINS or BIN_SIZE
    • init

      public void init(Histogram hist, int histType, int binType)
      Parameters:
      hist -
      histType -
      binType -
    • init

      public void init(Histogram hist, int histType, int binType, String xAxisPlotLabels)
      Parameters:
      hist -
      histType -
      binType -
    • setNumBins

      public void setNumBins(int nbins)
    • setBinSize

      public void setBinSize(double binSize)
    • setHistogramType

      public void setHistogramType(int type)
    • setBinType

      public void setBinType(int type)
    • setXmin

      public void setXmin(double xmin)
    • setXmax

      public void setXmax(double xmax)
    • setSeriesColor

      public void setSeriesColor()
    • getHistogram

      public Histogram getHistogram()
    • getChart

      public org.jfree.chart.JFreeChart getChart()
      Overrides:
      getChart in class org.jfree.chart.ChartPanel
    • getChartPanel

      public org.jfree.chart.ChartPanel getChartPanel()
    • getNumBins

      public int getNumBins()
    • getBinSize

      public double getBinSize()
    • update

      public void update()
    • updateWithNoReconstruction

      public void updateWithNoReconstruction()
    • plot

      public void plot()
    • getImage

      public Image getImage(String filePath)
    • plot

      public void plot(String histTitle, String dataName, String xLabel, String yLabel)
    • createDataset

      protected org.jfree.data.xy.IntervalXYDataset createDataset(String histTitle, int histType)
    • setAnalyticData

      public void setAnalyticData(double[] xA, double[] yA)
    • setPlotAnalytic

      public void setPlotAnalytic(boolean plotA)
    • hasPlotAnalytic

      public boolean hasPlotAnalytic()
    • plotAnalytic

      public void plotAnalytic()
    • gaussianArray

      public static double[] gaussianArray(int npts, double shift, double scale)
    • gaussianArray

      public static double[] gaussianArray(int npts)
    • analyticGaussian

      public static double[] analyticGaussian(double[] X)
    • zoomToAll

      public void zoomToAll()
    • replaceYOrdinateValue

      protected void replaceYOrdinateValue(PairedDataContainer pdc, double query, double replacement)
    • mouseClicked

      public void mouseClicked(MouseEvent e)
      Specified by:
      mouseClicked in interface MouseListener
      Overrides:
      mouseClicked in class org.jfree.chart.ChartPanel
    • showPopupPlot

      public void showPopupPlot()
    • setDisplayHistogramDialog

      public void setDisplayHistogramDialog(boolean displayHistogramDialog)
    • setBinSizeNoRebuild

      public void setBinSizeNoRebuild(double binSize)
    • setBinTypeNoRebuild

      public void setBinTypeNoRebuild(int binType)
    • setNumBinsNoRebuild

      public void setNumBinsNoRebuild(int length)
    • isDisplayHistogramDialog

      public boolean isDisplayHistogramDialog()
    • getHistTool

      public HistogramPlotDialog getHistTool()
    • setHistTool

      public void setHistTool(HistogramPlotDialog histTool)
    • getContainers

      public List<? extends DataContainer> getContainers()
    • setContainers

      public void setContainers(List<? extends DataContainer> containers)
    • setYLabel

      public void setYLabel(String yLabel)
    • setYLabel

      public void setYLabel()
    • setHistogramWeightProvider

      public void setHistogramWeightProvider(HistogramWeightProvider weightProvider)