Enum Class CurveDrawingMethod

java.lang.Object
java.lang.Enum<CurveDrawingMethod>
edu.cnu.mdi.splot.fit.CurveDrawingMethod
All Implemented Interfaces:
Serializable, Comparable<CurveDrawingMethod>, Constable

public enum CurveDrawingMethod extends Enum<CurveDrawingMethod>
Specifies how a curve should be drawn for a data set.

Historically this was named FitType, but that name was misleading because several options are not fits at all (e.g. connect, stairs, none).

Some drawing methods optionally consume a FitResult (Apache Commons Math based), or a CubicSpline.

  • Enum Constant Details

    • NONE

      public static final CurveDrawingMethod NONE
      No curve drawn.
    • CONNECT

      public static final CurveDrawingMethod CONNECT
      Simple line segments connecting points.
    • STAIRS

      public static final CurveDrawingMethod STAIRS
      Stair-step connection between points.
    • CUBICSPLINE

      public static final CurveDrawingMethod CUBICSPLINE
      Natural cubic spline interpolation (not a fit).
    • POLYNOMIAL

      public static final CurveDrawingMethod POLYNOMIAL
      Polynomial least-squares fit.
    • GAUSSIAN

      public static final CurveDrawingMethod GAUSSIAN
      Single Gaussian fit.
    • GAUSSIANS

      public static final CurveDrawingMethod GAUSSIANS
      Multiple Gaussian fit (sum of Gaussians).
    • ERF

      public static final CurveDrawingMethod ERF
      Error function fit.
    • ERFC

      public static final CurveDrawingMethod ERFC
      Complementary error function fit.
    • EXPONENTIAL_DECAY

      public static final CurveDrawingMethod EXPONENTIAL_DECAY
      Exponential decay fit: A·exp(-x/τ) + C.
    • POWER_LAW

      public static final CurveDrawingMethod POWER_LAW
      Power law fit: A·x^n + C.
    • LORENTZIAN

      public static final CurveDrawingMethod LORENTZIAN
      Lorentzian (Breit-Wigner / Cauchy) resonance peak fit.
  • Method Details

    • values

      public static CurveDrawingMethod[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static CurveDrawingMethod valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getName

      public String getName()
      UI-friendly name for combo boxes, menus, etc.
      Returns:
      display name
    • toString

      public String toString()
      Overrides:
      toString in class Enum<CurveDrawingMethod>
    • getValue

      public static CurveDrawingMethod getValue(String s)
      Find a method by display name or enum constant name (case-insensitive).
      Parameters:
      s - display name or enum name
      Returns:
      matching method, or null if none