Class TrendlineImpl

java.lang.Object
io.keikai.model.impl.chart.TrendlineImpl
All Implemented Interfaces:
STrendline, Serializable

public class TrendlineImpl extends Object implements STrendline, Serializable
Default implementation of STrendline.
Since:
7.0.0
See Also:
  • Constructor Details

  • Method Details

    • getType

      public STrendline.TrendlineType getType()
      Description copied from interface: STrendline
      Returns the trendline type.
      Specified by:
      getType in interface STrendline
    • setType

      public void setType(STrendline.TrendlineType type)
      Description copied from interface: STrendline
      Sets the trendline type.
      Specified by:
      setType in interface STrendline
    • getOrder

      public int getOrder()
      Description copied from interface: STrendline
      Returns the polynomial order (valid range 2-6, only meaningful when type is POLYNOMIAL).
      Specified by:
      getOrder in interface STrendline
    • setOrder

      public void setOrder(int order)
      Description copied from interface: STrendline
      Sets the polynomial order (valid range 2-6).
      Specified by:
      setOrder in interface STrendline
    • getPeriod

      public int getPeriod()
      Description copied from interface: STrendline
      Returns the moving-average period (only meaningful when type is MOVING_AVERAGE).
      Specified by:
      getPeriod in interface STrendline
    • setPeriod

      public void setPeriod(int period)
      Description copied from interface: STrendline
      Sets the moving-average period.
      Specified by:
      setPeriod in interface STrendline
    • getForward

      public double getForward()
      Description copied from interface: STrendline
      Returns the number of periods to forecast forward.
      Specified by:
      getForward in interface STrendline
    • setForward

      public void setForward(double periods)
      Description copied from interface: STrendline
      Sets the number of periods to forecast forward.
      Specified by:
      setForward in interface STrendline
    • getBackward

      public double getBackward()
      Description copied from interface: STrendline
      Returns the number of periods to forecast backward.
      Specified by:
      getBackward in interface STrendline
    • setBackward

      public void setBackward(double periods)
      Description copied from interface: STrendline
      Sets the number of periods to forecast backward.
      Specified by:
      setBackward in interface STrendline
    • getIntercept

      public Double getIntercept()
      Description copied from interface: STrendline
      Returns the forced intercept value, or null if auto.
      Specified by:
      getIntercept in interface STrendline
    • setIntercept

      public void setIntercept(Double intercept)
      Description copied from interface: STrendline
      Sets the forced intercept value. Pass null for auto.
      Specified by:
      setIntercept in interface STrendline
    • isDisplayRSquared

      public boolean isDisplayRSquared()
      Description copied from interface: STrendline
      Returns whether the R-squared value is displayed on the chart.
      Specified by:
      isDisplayRSquared in interface STrendline
    • setDisplayRSquared

      public void setDisplayRSquared(boolean display)
      Description copied from interface: STrendline
      Sets whether the R-squared value is displayed on the chart.
      Specified by:
      setDisplayRSquared in interface STrendline
    • isDisplayEquation

      public boolean isDisplayEquation()
      Description copied from interface: STrendline
      Returns whether the equation is displayed on the chart.
      Specified by:
      isDisplayEquation in interface STrendline
    • setDisplayEquation

      public void setDisplayEquation(boolean display)
      Description copied from interface: STrendline
      Sets whether the equation is displayed on the chart.
      Specified by:
      setDisplayEquation in interface STrendline
    • getName

      public String getName()
      Description copied from interface: STrendline
      Returns the custom name of this trendline, or null if using the default.
      Specified by:
      getName in interface STrendline
    • setName

      public void setName(String name)
      Description copied from interface: STrendline
      Sets the custom name of this trendline.
      Specified by:
      setName in interface STrendline