|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.rosuda.JRclient.RFactor
public class RFactor
representation of a factor variable. In R there is no actual xpression type called "factor", instead it is coded as an int vector with a list attribute. The parser code of REXP converts such constructs directly into the RFactor objects and defines an own XT_FACTOR type
Constructor Summary | |
---|---|
RFactor()
create a new, empty factor var |
|
RFactor(int[] i,
java.lang.String[] v)
create a new factor variable, based on the supplied arrays. |
|
RFactor(int[] i,
java.util.Vector v)
special constructor used by REXP parser to save some re-indexing and performing automatic index conversion |
Method Summary | |
---|---|
void |
add(java.lang.String v)
add a new element (by name) |
java.lang.String |
at(int i)
returns name for a specific ID |
int |
size()
returns the number of caes |
java.lang.String |
toString()
displayable representation of the factor variable |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public RFactor()
public RFactor(int[] i, java.lang.String[] v)
i
- array if IDs (0..v.length-1)v
- values - cotegory namespublic RFactor(int[] i, java.util.Vector v)
i
- index arrayv
- vector of xpressions which should be all stringsMethod Detail |
---|
public void add(java.lang.String v)
v
- valuepublic java.lang.String at(int i)
i
- ID
public int size()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |