infovis.column.visualization
Class HistogramVisualization

java.lang.Object
  extended by infovis.utils.ChangeManager
      extended by infovis.column.AbstractColumn
          extended by infovis.column.ColumnProxy
              extended by infovis.table.TableProxy
                  extended by infovis.visualization.DefaultVisualization
                      extended by infovis.column.visualization.ColumnVisualization
                          extended by infovis.column.visualization.HistogramVisualization
All Implemented Interfaces:
IntComparator, Column, Metadata, Constants, Table, RowComparator, Visualization, Layout, LabeledComponent, Orientable, Serializable, EventListener, ChangeListener, TableModelListener, SwingConstants, TableModel

public class HistogramVisualization
extends ColumnVisualization

Visualization of histogram.

Version:
$Revision: 1.1 $
Author:
Jean-Daniel Fekete
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface infovis.visualization.magicLens.LabeledComponent
LabeledComponent.LabeledItem
 
Field Summary
 
Fields inherited from class infovis.column.AbstractColumn
MODIFIED_ALL, MODIFIED_NONE
 
Fields inherited from interface infovis.Visualization
PROPERTY_INTERACTOR, PROPERTY_ITEM_RENDERER, PROPERTY_LAYOUT, PROPERTY_ORIENTATION, PROPERTY_PARENT, PROPERTY_PERMUTATION, PROPERTY_RULERS, VC_DESCRIPTOR_PROPERTY_PREFIX, VISUAL_ALPHA, VISUAL_COLOR, VISUAL_FILTER, VISUAL_HOVER, VISUAL_LABEL, VISUAL_SELECTION, VISUAL_SHAPE, VISUAL_SIZE
 
Fields inherited from interface infovis.visualization.Orientable
DIRECTION, NAME, ORIENTATION_CENTER, ORIENTATION_EAST, ORIENTATION_INVALID, ORIENTATION_NORTH, ORIENTATION_SOUTH, ORIENTATION_WEST, SQRT2
 
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
 
Fields inherited from interface infovis.Table
FILTER_COLUMN, INTERNAL_PREFIX, NIL, SELECTION_COLUMN
 
Fields inherited from interface infovis.metadata.Constants
CONTRIBUTOR, COVERAGE, CREATOR, DATE, DESCRITION, FORMAT, IDENTIFIER, LANGUAGE, PUBLISHER, RELATION, RIGHTS, SOURCE, SUBJECT, TITLE, TYPE
 
Constructor Summary
HistogramVisualization(NumberColumn column)
          Constructor.
HistogramVisualization(NumberColumn column, int bins)
          Constructor.
 
Method Summary
 int getBins()
          Returns the number of bins of this histogram.
 HistogramColumn getHistogram()
           
 Dimension getPreferredSize(Visualization vis)
          Computes and return the preferred size for this layout and this visualization.
 void setBins(int bins)
          Change the number of bins of the histogram.
 boolean setColumn(Column column)
          Sets the visualized column.
 void setHistogramColumn(NumberColumn column)
          Change the column of the histogram.
 
Methods inherited from class infovis.column.visualization.ColumnVisualization
computeShapes, getColumn, getLayout, getName, invalidate
 
Methods inherited from class infovis.visualization.DefaultVisualization
addPropertyChangeListener, addPropertyChangeListener, computeMinMax, computeMinMaxFiltered, computeShapes, createLabelItem, dispose, findRectAt, findVisualization, firePropertyChange, firePropertyChange, firePropertyChange, fireVisualColumnDescriptorChanged, freeRectAt, getBounds, getComponent, getFilter, getFisheye, getInteractor, getItemRenderer, getItemRenderer, getItemRenderer, getOrientation, getParent, getPermutation, getPreferredSize, getRectAt, getRowAtIndex, getRowCount, getRowIndex, getRulerTable, getSelection, getShapeAt, getShapeBoundsAt, getShapes, getTable, getVisualColumn, getVisualColumnDescriptor, getVisualColumnIterator, getVisualization, getVisualizationBounds, invalidate, invalidate, isFiltered, isInvalidateColumn, isInvalidated, iterator, paint, paintItem, paintItems, paintVisualizations, pickAll, pickAll, pickItem, pickTop, pickTop, print, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, reverseIterator, setFisheye, setInteractor, setItemRenderer, setOrientation, setParent, setPermutation, setShapeAt, setVisualColumn, stateChanged, tableChanged, validateShapes
 
Methods inherited from class infovis.table.TableProxy
addColumn, addTableModelListener, clear, getColumn, getColumnAt, getColumnClass, getColumnCount, getColumnName, getLastRow, getValueAt, indexOf, indexOf, isCellEditable, isRowValid, removeColumn, removeTableModelListener, setColumnAt, setValueAt
 
Methods inherited from class infovis.column.ColumnProxy
addValue, addValueOrNull, capacity, compare, ensureCapacity, getClientProperty, getFormat, getMaxIndex, getMetadata, getMinIndex, getValueAt, getValueClass, hasUndefinedValue, isEmpty, isInternal, isValueUndefined, setFormat, setName, setSize, setValueAt, setValueOrNullAt, setValueUndefined, size
 
Methods inherited from class infovis.column.AbstractColumn
addChangeListener, compareValues, computeValueMap, computeValueMap, equalObj, equals, getLastModifiedRow, toString
 
Methods inherited from class infovis.utils.ChangeManager
disableNotify, enableNotify, getModCount, removeChangeListener
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface infovis.Column
addChangeListener, addValue, addValueOrNull, capacity, disableNotify, enableNotify, ensureCapacity, getFormat, getMaxIndex, getMinIndex, getValueAt, getValueClass, hasUndefinedValue, isEmpty, isInternal, isValueUndefined, removeChangeListener, setFormat, setName, setSize, setValueAt, setValueOrNullAt, setValueUndefined, size
 
Methods inherited from interface infovis.Metadata
getClientProperty, getMetadata
 
Methods inherited from interface cern.colt.function.IntComparator
compare, equals
 

Constructor Detail

HistogramVisualization

public HistogramVisualization(NumberColumn column,
                              int bins)
Constructor.

Parameters:
column - the column to build a histogram.
bins - number of bins.

HistogramVisualization

public HistogramVisualization(NumberColumn column)
Constructor.

Parameters:
column - the column to build a histogram.
Method Detail

getHistogram

public HistogramColumn getHistogram()
Returns:
Returns the histogram.

setColumn

public boolean setColumn(Column column)
Sets the visualized column.

Overrides:
setColumn in class ColumnVisualization
Parameters:
column - the column
Returns:
true if the visualized column has been changed.

setHistogramColumn

public void setHistogramColumn(NumberColumn column)
Change the column of the histogram.

Parameters:
column - the new column.

setBins

public void setBins(int bins)
Change the number of bins of the histogram.

Parameters:
bins - the new bin number

getBins

public int getBins()
Returns the number of bins of this histogram.

Returns:
the number of bins of this histogram.

getPreferredSize

public Dimension getPreferredSize(Visualization vis)
Computes and return the preferred size for this layout and this visualization.

Specified by:
getPreferredSize in interface Layout
Overrides:
getPreferredSize in class ColumnVisualization
Parameters:
vis - the visualization
Returns:
the preferred size for this layout and this visualization.


Copyright © 2005 by Jean-Daniel Fekete and INRIA, France All rights reserved.