com.jstatcom.equation
Class EqTermEC

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by javax.swing.JComponent
              extended by javax.swing.JPanel
                  extended by com.jstatcom.equation.EqTerm
                      extended by com.jstatcom.equation.EqTermEC
All Implemented Interfaces:
java.awt.image.ImageObserver, java.awt.MenuContainer, java.beans.PropertyChangeListener, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible

public final class EqTermEC
extends EqTerm
implements java.beans.PropertyChangeListener

A special equation term for the error correction term in a VEC model. It contains a coefficients table for the alpha, beta and beta_d (for restricted deterministics) parameters. The variable names are separated between endogenous variables and deterministic variables restricted to the EC term. In addition it is possible to set subset restrictions corresponding to the respective parameters.

Clients should make sure that the underlying data objects have the correct dimensions and ordering of variables for the display to be in sync with the data.

Author:
Alexander Benkwitz, Markus Kraetzig
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.BaselineResizeBehavior
 
Field Summary
 
Fields inherited from class javax.swing.JComponent
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
EqTermEC()
          Constructor.
 
Method Summary
 int getColumnWidth()
          Gets the column width of the alpha table.
 java.awt.event.MouseListener getMouseListenerCoeff()
          Gets the mouse listener of the underlying coefficients tables.
 int getPrecision()
          Gets the precision of the underlying coefficients tables.
 javax.swing.table.TableCellRenderer getRendererCoeff()
          Gets the cell renderer of the underlying coefficients tables.
 java.lang.String getSymbolNameAlphaCoeff()
          Gets the symbolname for the alpha coefficients.
 java.lang.String getSymbolNameAlphaSubsetRes()
          Gets the symbolname for the subset restrictions corresponding to the alpha coefficients.
 java.lang.String getSymbolNameBetaCoeff()
          Gets the symbolname for the beta coefficients of the endogenous variables.
 java.lang.String getSymbolNameBetaDetCoeff()
          Gets the symbolname for the beta coefficients of the restricted deterministic variables.
 java.lang.String getSymbolNameBetaDetSubsetRes()
          Gets the symbolname for the subset restrictions corresponding to the beta coefficients of the restricted deterministic variables.
 java.lang.String getSymbolNameBetaSubsetRes()
          Gets the symbolname for the subset restrictions corresponding to the beta coefficients of the endogenous variables.
 java.lang.String getSymbolNameDetVarNames()
          Gets the symbolname for the names of the deterministic variables.
 java.lang.String getSymbolNameEndVarNames()
          Gets the symbolname for the names of the endogenous variables.
 boolean isEditable()
          Gets whether the underlying coefficients tables are editable.
 void propertyChange(java.beans.PropertyChangeEvent evt)
          Manages visibility of all terms with respect to the available coefficients.
 void setColumnWidth(int colWidth)
          Sets the column width of the underlying coefficients tables.
 void setEditable(boolean isEditable)
          Sets whether the underlying coefficients tables are editable.
 void setLeadingSignVisible(boolean isVisible)
          Manages visibility of the leading sign label.
 void setMouseListenerCoeff(java.awt.event.MouseListener arg)
          Sets the mouse listener for the underlying coefficients tables.
 void setPrecision(int precision)
          Sets the precision for the underlying coefficients tables.
 void setRendererCoeff(javax.swing.table.TableCellRenderer renderer)
          Sets the cell renderer for the underlying coefficients tables.
 void setSymbolNameAlphaCoeff(java.lang.String symbolName)
          Sets the symbolname for the alpha coefficients.
 void setSymbolNameAlphaSubsetRes(java.lang.String symbolName)
          Sets the symbolname for the subset restrictions corresponding to the alpha coefficients.
 void setSymbolNameBetaCoeff(java.lang.String symbolName)
          Sets the symbolname for the beta coefficients of the endogenous variables.
 void setSymbolNameBetaDetCoeff(java.lang.String symbolName)
          Sets the symbolname for the beta coefficients of the restricted deterministic variables.
 void setSymbolNameBetaDetSubsetRes(java.lang.String symbolName)
          Sets the symbolname for the subset restrictions corresponding to the beta coefficients of the restricted deterministic variables.
 void setSymbolNameBetaSubsetRes(java.lang.String symbolName)
          Sets the symbolname for the subset restrictions corresponding to the beta coefficients of the endogenous variables.
 void setSymbolNameDetVarNames(java.lang.String symbolName)
          Sets the symbolname for the names of the deterministic variables.
 void setSymbolNameEndVarNames(java.lang.String symbolName)
          Sets the symbolname for the names of the endogenous variables.
 void setSymbolScope(Scope scope)
          Sets the symbol scope, which defines which symbol table to use (local, global or upper).
 
Methods inherited from class com.jstatcom.equation.EqTerm
getMaximumSize, getMinimumSize, getPreferredSize, getSymbolScope, setDataAvailable, setVisible
 
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, setUI, updateUI
 
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, unregisterKeyboardAction, update
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusBackward, transferFocusDownCycle, validate
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EqTermEC

public EqTermEC()
Constructor.

Method Detail

getColumnWidth

public int getColumnWidth()
Gets the column width of the alpha table.

Returns:
column width

getMouseListenerCoeff

public java.awt.event.MouseListener getMouseListenerCoeff()
Gets the mouse listener of the underlying coefficients tables.

Returns:
java.awt.event.MouseListener

getPrecision

public int getPrecision()
Gets the precision of the underlying coefficients tables.

Returns:
precision

getRendererCoeff

public javax.swing.table.TableCellRenderer getRendererCoeff()
Gets the cell renderer of the underlying coefficients tables.

Returns:
javax.swing.table.TableCellRenderer

getSymbolNameAlphaCoeff

public java.lang.String getSymbolNameAlphaCoeff()
Gets the symbolname for the alpha coefficients.

Returns:
symbol name

getSymbolNameAlphaSubsetRes

public java.lang.String getSymbolNameAlphaSubsetRes()
Gets the symbolname for the subset restrictions corresponding to the alpha coefficients.

Returns:
symbol name

getSymbolNameBetaCoeff

public java.lang.String getSymbolNameBetaCoeff()
Gets the symbolname for the beta coefficients of the endogenous variables.

Returns:
symbol name

getSymbolNameBetaDetCoeff

public java.lang.String getSymbolNameBetaDetCoeff()
Gets the symbolname for the beta coefficients of the restricted deterministic variables.

Returns:
symbol name

getSymbolNameBetaDetSubsetRes

public java.lang.String getSymbolNameBetaDetSubsetRes()
Gets the symbolname for the subset restrictions corresponding to the beta coefficients of the restricted deterministic variables.

Returns:
symbol name

getSymbolNameBetaSubsetRes

public java.lang.String getSymbolNameBetaSubsetRes()
Gets the symbolname for the subset restrictions corresponding to the beta coefficients of the endogenous variables.

Returns:
symbol name

getSymbolNameDetVarNames

public java.lang.String getSymbolNameDetVarNames()
Gets the symbolname for the names of the deterministic variables.

Returns:
symbol name

getSymbolNameEndVarNames

public java.lang.String getSymbolNameEndVarNames()
Gets the symbolname for the names of the endogenous variables.

Returns:
symbol name

isEditable

public boolean isEditable()
Gets whether the underlying coefficients tables are editable.

Returns:
true if editable

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent evt)
Manages visibility of all terms with respect to the available coefficients.

Specified by:
propertyChange in interface java.beans.PropertyChangeListener
Parameters:
evt - property change event

setColumnWidth

public void setColumnWidth(int colWidth)
Sets the column width of the underlying coefficients tables.

Parameters:
colWidth - column width

setEditable

public void setEditable(boolean isEditable)
Sets whether the underlying coefficients tables are editable.

Parameters:
isEditable - true if editable

setLeadingSignVisible

public void setLeadingSignVisible(boolean isVisible)
Manages visibility of the leading sign label.

Specified by:
setLeadingSignVisible in class EqTerm
Parameters:
isVisible - true if visible

setSymbolScope

public void setSymbolScope(Scope scope)
Sets the symbol scope, which defines which symbol table to use (local, global or upper).

Overrides:
setSymbolScope in class EqTerm
Parameters:
scope - the symbol scope
Throws:
java.lang.IllegalArgumentException - if (scope == null)

setMouseListenerCoeff

public void setMouseListenerCoeff(java.awt.event.MouseListener arg)
Sets the mouse listener for the underlying coefficients tables.

Parameters:
arg - java.awt.event.MouseListener

setPrecision

public void setPrecision(int precision)
Sets the precision for the underlying coefficients tables.

Parameters:
precision -

setRendererCoeff

public void setRendererCoeff(javax.swing.table.TableCellRenderer renderer)
Sets the cell renderer for the underlying coefficients tables.

Parameters:
renderer - javax.swing.table.TableCellRenderer

setSymbolNameAlphaCoeff

public void setSymbolNameAlphaCoeff(java.lang.String symbolName)
Sets the symbolname for the alpha coefficients.

Parameters:
symbolName - for alpha

setSymbolNameAlphaSubsetRes

public void setSymbolNameAlphaSubsetRes(java.lang.String symbolName)
Sets the symbolname for the subset restrictions corresponding to the alpha coefficients.

Parameters:
symbolName - for alpha restrictions

setSymbolNameBetaCoeff

public void setSymbolNameBetaCoeff(java.lang.String symbolName)
Sets the symbolname for the beta coefficients of the endogenous variables.

Parameters:
symbolName - for beta

setSymbolNameBetaDetCoeff

public void setSymbolNameBetaDetCoeff(java.lang.String symbolName)
Sets the symbolname for the beta coefficients of the restricted deterministic variables.

Parameters:
symbolName - for beta_d

setSymbolNameBetaDetSubsetRes

public void setSymbolNameBetaDetSubsetRes(java.lang.String symbolName)
Sets the symbolname for the subset restrictions corresponding to the beta coefficients of the restricted deterministic variables.

Parameters:
symbolName - for beta_d subset restrictions

setSymbolNameBetaSubsetRes

public void setSymbolNameBetaSubsetRes(java.lang.String symbolName)
Sets the symbolname for the subset restrictions corresponding to the beta coefficients of the endogenous variables.

Parameters:
symbolName - for beta subset restrictions

setSymbolNameDetVarNames

public void setSymbolNameDetVarNames(java.lang.String symbolName)
Sets the symbolname for the names of the deterministic variables.

Parameters:
symbolName - for deterministics variable names

setSymbolNameEndVarNames

public void setSymbolNameEndVarNames(java.lang.String symbolName)
Sets the symbolname for the names of the endogenous variables.

Parameters:
symbolName - for endogenous variable names