Class PoMultipleHistogram

  • All Implemented Interfaces:
    SafeDisposable

    public class PoMultipleHistogram
    extends PoHistogram
    Class to build a multiple histogram. Class to build a multiple histogram in the plane XY. This histogram is based on multiple statistical data. Multiple statistical data is composed of a matrix of values associated to a list of column names and a list of row names.

    The histogram bars are perpendicular to the X-axis or to the Y-axis (according to the field type). The statistic values correspond to the height (or width) of the bars.

    There are three possible representations of multiple histograms:

    • The histogram values are juxtaposed.
    • The histogram values are accumulated.
    • The histogram values are percentages.

    The bars of the histogram can be colored using the fields color and coloring. If the bars colors are defined by a list of colors (coloring = COLOR_LIST), according to the field histogPath, the list of colors is associated to the rows or to the columns and color.getNum() must be greater or equal to getNum(), otherwise all the bars get the same color which is the inherited color.

    File format/default:

    PoMultipleHistogram {

      start 0 0
      end 1
      type X
      color 0 0 0
      coloring COLOR_LIST
      valueVisibility VISIBILITY_ON
      valuePosition POS_DEPEND
      valuePath PATH_DEPEND
      valueFontSize 0.0
      valueFontName ""
      valueAddStringVisibility false
      valueAddString ""
      nameVisibility VISIBILITY_ON
      namePosition POS_DEPEND
      namePath PATH_DEPEND
      nameFontSize 0.0
      nameFontName ""
      barSpaceType REL_SPACE
      barSpaceValue 0.25
      representation JUXTAPOSED
      barHeight 1.0
      numRows 1
      numColumns 1
      value 0
      rowName ""
      columnName ""
      histogPath ROW_COLUM
      sumVisibility VISIBILITY_ON
      sumPosition POS_DEPEND
      sumPath PATH_DEPEND
      sumFontSize 0.0
      sumFontName ""
    }

    <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> <html> <head> <link REL="stylesheet" TYPE="text/css" HREF="../../stylesheet.css" TITLE="Style"> <title></title> </head> <BODY> <h1></h1> <h4> <A NAME="Heading780">CATALOG PARTS</A></h4> <ul><b>PoMultipleHistogram</b> {</ul> <ul><ul><b>Separator</b> <tt>alternateRep</tt> (from PoBase) {<br> </ul></ul> <ul><ul><ul><b>AppearanceKit</b> <tt>appearance</tt> (from PoBase)</ul></ul></ul> <ul><ul><ul><i>Specifies the appearance of all the kit. By default lightModel.model=BASE_COLOR.</i></ul></ul></ul> <ul><ul><ul><b>MatrixTransform</b> <tt>domainTransform</tt> (from PoBase)</ul></ul></ul> <ul><ul><ul><i>Corresponds to the domain transformation.</i></ul></ul></ul> <ul><ul><ul><b>MatrixTransform</b> <tt>transform</tt> (from PoHistogram)</ul></ul></ul> <ul><ul><ul><i>Corresponds to the orientation of the histogram.</i></ul></ul></ul> <ul><ul><ul><ul></ul></ul></ul></ul> <ul><ul><ul><b>Separator</b> <tt>barSep</tt> (from PoHistogram) {</ul></ul></ul> <ul><ul><ul><i>Contains properties and shapes to draw the bars of the histogram.</i></ul></ul></ul> <ul><ul><ul><ul><b>AppearanceKit</b> <tt>barApp </tt>(from PoHistogram)</ul></ul></ul></ul> <ul><ul><ul><ul><i>Specifies the appearance of the bars of the histogram. material.diffuseColor is set (only if bars are colored) when the kit is rebuilt.</i></ul></ul></ul></ul> <ul><ul><ul><ul><b>Group</b> <tt>bar</tt> (from PoHistogram)</ul></ul></ul></ul> <ul><ul><ul><ul><i>Contains a SoFaceSet shape to draw the bars of the histogram.</i></ul></ul></ul></ul> <ul><ul><ul>}<br> <br> <b>Separator</b> <tt>valueTextSep</tt> (from PoHistogram) {</ul></ul></ul> <ul><ul><ul><i>Contains properties and shapes to draw the text of values of the histogram.</i></ul></ul></ul> <ul><ul><ul><ul><b>AppearanceKit</b> <tt>valueTexApp </tt>(from PoHistogram)</ul></ul></ul></ul> <ul><ul><ul><ul><i>Specifies the appearance of the text of values of the histogram. By default drawStyle.style=LINES. font.size and font.name are set when the kit is rebuilt.</i></ul></ul></ul></ul> <ul><ul><ul><ul><b>Group</b> <tt>valueText</tt> (from PoHistogram)</ul></ul></ul></ul> <ul><ul><ul><ul><i>Contains a list of SoAnnoText3 shapes to draw the text of values of the histogram.</i></ul></ul></ul></ul> <ul><ul><ul>}<br> <br> <b>Separator</b> <tt>nameTextSep</tt> (from PoHistogram) {</ul></ul></ul> <ul><ul><ul><i>Contains properties and shapes to draw the bars names text of the histogram.</i></ul></ul></ul> <ul><ul><ul><ul><b>AppearanceKit</b> <tt>nameTexApp </tt>(from PoHistogram)</ul></ul></ul></ul> <ul><ul><ul><ul><i>Specifies the appearance of the bars names text of the histogram. By default drawStyle.style=LINES. font.size and font.name are set when the kit is rebuilt.</i></ul></ul></ul></ul> <ul><ul><ul><ul><b>Group</b> <tt>nameText</tt> (from PoHistogram)</ul></ul></ul></ul> <ul><ul><ul><ul><i>Contains a list of SoAnnoText3 shape to draw the bars names text of the histogram.</i></ul></ul></ul></ul> <ul><ul><ul>}<br> <br> <b>Separator</b> <tt>sumTextSep</tt> {</ul></ul></ul> <ul><ul><ul><i>Contains properties and shapes to draw the bars sums text of the histogram.</i></ul></ul></ul> <ul><ul><ul><ul><b>AppearanceKit</b> <tt>sumTextApp</tt></ul></ul></ul></ul> <ul><ul><ul><ul><i>Specifies the appearance of the bars sums text of the histogram. By default drawStyle.style=LINES. font.size and font.name are set when the kit is rebuilt.</i></ul></ul></ul></ul> <ul><ul><ul><ul><b>Group</b> <tt>sumText</tt></ul></ul></ul></ul> <ul><ul><ul><ul><i>Contains a list of SoAnnoText3 shape to draw the bars sums text of the histogram.</i></ul></ul></ul></ul> <ul><ul><ul>}</ul></ul></ul> <ul><ul>}</ul></ul> <ul>}</ul> <ul><ul><br> </ul></ul> </body> </html>

    • Field Detail

      • numRows

        public final SoSFUShort numRows
        Number of rows of the matrix of values.
      • numColumns

        public final SoSFUShort numColumns
        Number of columns of the matrix of values.
      • value

        public final SoMFFloat value
        Matrix of values.
      • rowName

        public final SoMFString rowName
        List of numRows names of the rows.
      • columnName

        public final SoMFString columnName
        List of numColumns names of the columns.
      • barHeight

        public final SoSFFloat barHeight
        This field is used only for percentage histogram representation (representation = PERCENTAGE) and it corresponds to the height of the histogram (in this representation, all the bars have the same size).
      • sumFontSize

        public final SoSFFloat sumFontSize
        Font size of bars sums. if this value is less or equal to 0, the font size is fixed at 0.04. This value is a percentage of the current domain (cf PoBase description).
      • sumFontName

        public final SoSFString sumFontName
        Font name of bars sums. If the font is equal to its default value, the font used is the font of the current miscellaneous text attributes (cf PoHistogram description).
    • Constructor Detail

      • PoMultipleHistogram

        public PoMultipleHistogram()
        Default constructor.
      • PoMultipleHistogram

        public PoMultipleHistogram​(SbVec2f _start,
                                   float _end,
                                   PoHistogram.Types _type,
                                   int _numRows,
                                   int _numColumns,
                                   float[] _value,
                                   java.lang.String[] _rowName,
                                   java.lang.String[] _columnName)
        Constructor.