Class AbstractScatterPlot

    • Field Detail

      • m_Data

        protected SpreadSheet m_Data
        Instances to be plotted
      • m_XIntIndex

        protected int m_XIntIndex
        Index of attribute to be displayed on x axis
      • m_YIntIndex

        protected int m_YIntIndex
        Index of attribute to be displayed on y axis
    • Constructor Detail

      • AbstractScatterPlot

        public AbstractScatterPlot()
    • Method Detail

      • setPaintlet

        public void setPaintlet​(AbstractScatterPlotPaintlet val)
        Set the paintlet for dawing the data
        Parameters:
        val - Paintlet for plotting
      • canPaint

        protected boolean canPaint​(Graphics g)
        Description copied from class: PaintablePanel
        Returns true if the paintlets can be executed.
        Specified by:
        canPaint in class PaintablePanel
        Parameters:
        g - the graphics context
        Returns:
        true if painting can go ahead
      • setData

        public void setData​(SpreadSheet data)
        Sets the instances to be plotted
        Parameters:
        data - Instances to be plotted
      • getData

        public SpreadSheet getData()
        Get the instances being plotted
        Returns:
        Instances being plotted
      • getXIntIndex

        public int getXIntIndex()
        gets the index of the x attribute
        Returns:
        index of x attribute
      • getYIntIndex

        public int getYIntIndex()
        Sets the index of the y attribute
        Returns:
        index of y attribute
      • removeOverlays

        public void removeOverlays()
        Removes all overlays from the scatterplot. Removes the paintlets that do the drawing as well as resetting the array
      • setXIntIndex

        public void setXIntIndex​(int value)
        Set the index of the attribute to be displayed on the x axis
        Parameters:
        value - 0-based index of attribute
      • setYIntIndex

        public void setYIntIndex​(int value)
        Set the index of the attribute to be displayed on the y axis
        Parameters:
        value - 0-based index of attribute
      • processTipText

        public String processTipText​(PlotPanel panel,
                                     Point mouse,
                                     String tiptext)
        Processes the given tip text. Among the current mouse position, the panel that initiated the call are also provided.
        Specified by:
        processTipText in interface TipTextCustomizer
        Parameters:
        panel - the content panel that initiated this call
        mouse - the mouse position
        tiptext - the tiptext so far
        Returns:
        the processed tiptext
      • supplyText

        public String supplyText()
        Supplies the text. May get called even if actor hasn't been executed yet.
        Specified by:
        supplyText in interface TextSupplier
        Specified by:
        supplyText in interface TextSupporter
        Returns:
        the text, null if none available