|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.strbio.math.FVector
org.strbio.math.FHalfMatrix
public class FHalfMatrix
like an upper triangular DMatrix. This pretends that you have a NxN matrix, but only allows access to elements in the upper triangular part (not including the diagonal). Allowed elements are of the form (i, i+1...n-1). You can access the data[] directly or call inherited methods from FVector, but you SHOULDN'T DO THIS.
DMatrix| Field Summary |
|---|
| Fields inherited from class org.strbio.math.FVector |
|---|
data |
| Constructor Summary | |
|---|---|
FHalfMatrix()
Makes a new FHalfMatrix with no data. |
|
FHalfMatrix(FHalfMatrix x)
This makes a FHalfMatrix from another one, making a separate copy of the data. |
|
FHalfMatrix(int x)
This makes a new FHalfMatrix which is the upper triangular part of a square matrix. |
|
| Method Summary | |
|---|---|
int |
cols()
Returns the number of columns (of the theoretical whole matrix, not just the upper triangular part. |
void |
load(java.io.BufferedReader fp)
Loads from an open BufferedReader. |
void |
print(PrintfStream outfile)
Print nicely formatted data to a PrintfStream. |
int |
rows()
Returns the number of rows (of the theoretical whole matrix, not just the upper triangular part. |
void |
setValueAt(int x,
int y,
float d)
This allows you to set a value at column x, row y in the theoretical whole matrix. |
float |
valueAt(int x,
int y)
This allows you to get a value at column x, row y in the theoretical whole matrix. |
| Methods inherited from class org.strbio.math.FVector |
|---|
add, add, append, append, average, averageRW, covar, cross, cross, dimension, distance, distance, divide, divide, dot, dot, equals, findNClosest, length, linearFit, load, makeZScores, max, median, min, multiply, multiply, multiply, multiply, multiply, multiply, norm, normalize, pearson, print, reverse, reverse, save, save, setValue, setValueAt, sort, stdev, stdevp, subtract, subtract, transform, valueAt, zScore |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public FHalfMatrix(int x)
x - the number of rows and columns (x by x matrix)public FHalfMatrix()
public FHalfMatrix(FHalfMatrix x)
| Method Detail |
|---|
public final int rows()
public final int cols()
public final float valueAt(int x,
int y)
x - column numbery - row number
public final void setValueAt(int x,
int y,
float d)
x - column numbery - row numberd - float to store
public final void print(PrintfStream outfile)
throws java.io.IOException
java.io.IOException
public final void load(java.io.BufferedReader fp)
throws java.io.IOException
load in class FVectorjava.io.IOExceptionFVector
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||