|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.graphics.components.ClassificationVariable
public class ClassificationVariable
An ClassificationVariable is used by a graph when a sort order can be applied to the associated data values.
A ClassificationVariable is typically used when assigning a data column to a graph variable role that can be categorized. All string variables inherently use a discrete categorization whereas numeric values can be categorized into discrete values or formatted into separate groupings.
Example
You can apply an ascending sort order to the BarCharts category values by:
BarChart barChart = new BarChart(); TableModel tableModel = myTableModel(); // <...set up tableModel...> // create the graph's data model (contains a handle to the data source and // variables describing how to interpret the data) BarChartTableDataModel barChartTableDataModel = new BarChartTableDataModel(tableModel); // set the variable on the data model barChartTableDataModel.setCategoryVariable(categoryVariable); // set data model on the bar chart barChart.setDataModel( barChartTableDataModel );
Variable
,
VariableList
,
ClassificationVariableList
,
AnalysisVariable
,
AnalysisVariableList
Constructor Summary | |
---|---|
ClassificationVariable(ClassificationVariable cv)
Constructor for ClassificationVariable. |
|
ClassificationVariable(int columnIndex)
Constructor designating data column by index. |
|
ClassificationVariable(int columnIndex,
java.lang.String format,
java.lang.String informat,
java.lang.String label,
int sort)
Constructor designating data column by index along with the names of the SAS format and SAS informat and label to be applied. |
|
ClassificationVariable(int columnIndex,
java.lang.String format,
java.lang.String informat,
java.lang.String label,
int sort,
com.sas.graphics.components.CategorizationModel categorizationModel,
com.sas.graphics.components.SegmentedRangeStyle segmentedRangeStyle)
Constructor designating data column by index along with the names of the SAS format and SAS informat and label to be applied. |
|
ClassificationVariable(java.lang.String columnName)
Constructor designating data column by name. |
|
ClassificationVariable(java.lang.String columnName,
int sort)
Constructor designating data column by name and defining a sort order. |
|
ClassificationVariable(java.lang.String columnName,
java.lang.String format)
Constructor designating data column by name along with the name of the SAS format to be applied. |
|
ClassificationVariable(java.lang.String columnName,
java.lang.String format,
java.lang.String informat,
java.lang.String label,
int sort)
Constructor designating data column by name. |
|
ClassificationVariable(java.lang.String columnName,
java.lang.String format,
java.lang.String informat,
java.lang.String label,
int sort,
com.sas.graphics.components.CategorizationModel categorizationModel,
com.sas.graphics.components.SegmentedRangeStyle segmentedRangeStyle)
Constructor designating data column by name. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object obj)
Determines whether another object is equal to this ClassificationVariable . |
int |
getSort()
Returns the type of sort order applied to the values in the data column designated by this variable. |
int |
hashCode()
Computes the hash code for this ClassificationVariable . |
Methods inherited from class com.sas.graphics.components.Variable |
---|
getCategorizationModel, getColumnIndex, getColumnName, getFormat, getInformat, getLabel, getSegmentedRangeStyle |
Methods inherited from class com.sas.graphics.components.ModelBase |
---|
addPropertyChangeListener, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, removePropertyChangeListener, setContainedModel |
Constructor Detail |
---|
public ClassificationVariable(java.lang.String columnName)
columnName
- the name identifying the data columnpublic ClassificationVariable(java.lang.String columnName, int sort)
columnName
- the name identifying the data columnsort
- the sort order
Valid sort values are:
GraphConstants.SORT_NONE
GraphConstants.SORT_ASCENDING
GraphConstants.SORT_DESCENDING
GraphConstants.SORT_ASCENDING_FORMATTED
GraphConstants.SORT_DESCENDING_FORMATTED
GraphConstants.SORT_ASCENDING_UNFORMATTED
GraphConstants.SORT_DESCENDING_UNFORMATTED
GraphConstants
public ClassificationVariable(java.lang.String columnName, java.lang.String format)
columnName
- the name identifying the data columnformat
- the name of the SAS format applied
(by the graph) on the values found in
this variable's data columnpublic ClassificationVariable(java.lang.String columnName, java.lang.String format, java.lang.String informat, java.lang.String label, int sort)
columnName
- the name identifying the data columnformat
- the name of the SAS format applied
(by the graph) on the values found in
this variable's data columninformat
- the name of the SAS informat applied
(by the graph) on the values found in
this variable's data columnlabel
- the label the chart will display
via data tips, axis labels and legend labels
(where applicable)sort
- the sort order
The supported informats are:
DATE5. - "ddMMM"
DATE7. - "ddMMMyy"
DATE9. - "ddMMMyyyy"
DATETIME13. - "ddMMMyy:HH:mm"
DATETIME16. - "ddMMMyy:HH:mm:ss"
DATETIME18. - "ddMMMyyyy:HH:mm:ss"
DATETIME20. - "ddMMMyy:HH:mm:ss.SSS"
DATETIME22. - "ddMMMyyyy:HH:mm:ss.SSS"
TIME5. - "HH:mm"
TIME8. - "HH:mm:ss""
TIME12. - "HH:mm:ss.SSS"
Valid sort values are:
GraphConstants.SORT_NONE
GraphConstants.SORT_ASCENDING
GraphConstants.SORT_DESCENDING
GraphConstants.SORT_ASCENDING_FORMATTED
GraphConstants.SORT_DESCENDING_FORMATTED
GraphConstants.SORT_ASCENDING_UNFORMATTED
GraphConstants.SORT_DESCENDING_UNFORMATTED
GraphConstants
public ClassificationVariable(java.lang.String columnName, java.lang.String format, java.lang.String informat, java.lang.String label, int sort, com.sas.graphics.components.CategorizationModel categorizationModel, com.sas.graphics.components.SegmentedRangeStyle segmentedRangeStyle)
columnName
- the name identifying the data columnformat
- the name of the SAS format applied
(by the graph) on the values found in
this variable's data columninformat
- the name of the SAS informat applied
(by the graph) on the values found in
this variable's data columnlabel
- the label the chart will display
via data tips, axis labels and legend labels
(where applicable)sort
- the sort order
The supported informats are:
DATE5. - "ddMMM"
DATE7. - "ddMMMyy"
DATE9. - "ddMMMyyyy"
DATETIME13. - "ddMMMyy:HH:mm"
DATETIME16. - "ddMMMyy:HH:mm:ss"
DATETIME18. - "ddMMMyyyy:HH:mm:ss"
DATETIME20. - "ddMMMyy:HH:mm:ss.SSS"
DATETIME22. - "ddMMMyyyy:HH:mm:ss.SSS"
TIME5. - "HH:mm"
TIME8. - "HH:mm:ss""
TIME12. - "HH:mm:ss.SSS"
Valid sort values are:
GraphConstants.SORT_NONE
GraphConstants.SORT_ASCENDING
GraphConstants.SORT_DESCENDING
GraphConstants.SORT_ASCENDING_FORMATTED
GraphConstants.SORT_DESCENDING_FORMATTED
GraphConstants.SORT_ASCENDING_UNFORMATTED
GraphConstants.SORT_DESCENDING_UNFORMATTED
GraphConstants
public ClassificationVariable(int columnIndex)
columnIndex
- the index identifying the data columnpublic ClassificationVariable(int columnIndex, java.lang.String format, java.lang.String informat, java.lang.String label, int sort)
columnIndex
- the index identifying the data columnformat
- the name of the SAS format applied
(by the graph) on the values found in
this variable's data columninformat
- the name of the SAS informat applied
(by the graph) on the values found in
this variable's data columnlabel
- the label the chart will display
via data tips, axis labels and legend labels
(where applicable)sort
- the sort order
The supported informats are:
DATE5. - "ddMMM"
DATE7. - "ddMMMyy"
DATE9. - "ddMMMyyyy"
DATETIME13. - "ddMMMyy:HH:mm"
DATETIME16. - "ddMMMyy:HH:mm:ss"
DATETIME18. - "ddMMMyyyy:HH:mm:ss"
DATETIME20. - "ddMMMyy:HH:mm:ss.SSS"
DATETIME22. - "ddMMMyyyy:HH:mm:ss.SSS"
TIME5. - "HH:mm"
TIME8. - "HH:mm:ss""
TIME12. - "HH:mm:ss.SSS"
Valid sort values are:
GraphConstants.SORT_NONE
GraphConstants.SORT_ASCENDING
GraphConstants.SORT_DESCENDING
GraphConstants.SORT_ASCENDING_FORMATTED
GraphConstants.SORT_DESCENDING_FORMATTED
GraphConstants.SORT_ASCENDING_UNFORMATTED
GraphConstants.SORT_DESCENDING_UNFORMATTED
GraphConstants
public ClassificationVariable(int columnIndex, java.lang.String format, java.lang.String informat, java.lang.String label, int sort, com.sas.graphics.components.CategorizationModel categorizationModel, com.sas.graphics.components.SegmentedRangeStyle segmentedRangeStyle)
columnIndex
- the index identifying the data columnformat
- the name of the SAS format applied
(by the graph) on the values found in
this variable's data columninformat
- the name of the SAS informat applied
(by the graph) on the values found in
this variable's data columnlabel
- the label the chart will display
via data tips, axis labels and legend labels
(where applicable)sort
- the sort order
The supported informats are:
DATE5. - "ddMMM"
DATE7. - "ddMMMyy"
DATE9. - "ddMMMyyyy"
DATETIME13. - "ddMMMyy:HH:mm"
DATETIME16. - "ddMMMyy:HH:mm:ss"
DATETIME18. - "ddMMMyyyy:HH:mm:ss"
DATETIME20. - "ddMMMyy:HH:mm:ss.SSS"
DATETIME22. - "ddMMMyyyy:HH:mm:ss.SSS"
TIME5. - "HH:mm"
TIME8. - "HH:mm:ss""
TIME12. - "HH:mm:ss.SSS"
Valid sort values are:
GraphConstants.SORT_NONE
GraphConstants.SORT_ASCENDING
GraphConstants.SORT_DESCENDING
GraphConstants.SORT_ASCENDING_FORMATTED
GraphConstants.SORT_DESCENDING_FORMATTED
GraphConstants.SORT_ASCENDING_UNFORMATTED
GraphConstants.SORT_DESCENDING_UNFORMATTED
GraphConstants
public ClassificationVariable(ClassificationVariable cv)
cv
- Method Detail |
---|
public int getSort()
GraphConstants.SORT_NONE
GraphConstants.SORT_ASCENDING
GraphConstants.SORT_DESCENDING
GraphConstants.SORT_ASCENDING_FORMATTED
GraphConstants.SORT_DESCENDING_FORMATTED
GraphConstants.SORT_ASCENDING_UNFORMATTED
GraphConstants.SORT_DESCENDING_UNFORMATTED
GraphConstants
public boolean equals(java.lang.Object obj)
ClassificationVariable
.
The result is true
if and only if the argument is not
null
and is a ClassificationVariable
object that has the same
property values as this object.
equals
in class Variable
obj
- the object to test for equality with this
ClassificationVariable
true
if the objects are the same;
false
otherwise.public int hashCode()
ClassificationVariable
.
hashCode
in class Variable
|
Components |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |