public class HStatData extends Object implements Serializable
| Constructor and Description |
|---|
HStatData()
Initialise the container
|
HStatData(String description)
Initialse data for statistical analysis.
|
HStatData(String description,
String sfile)
Reads many data formats (in ASCII, Gauss, Matlab, Excel) and converts the
data (time series) to arrays for further processing.
|
| Modifier and Type | Method and Description |
|---|---|
void |
append(HStatData hs)
Append a row.
|
void |
doc()
Show online documentation.
|
double[] |
getColumn(int column)
Return a column as a array
|
com.jstatcom.model.JSCNArray |
getData()
Return data as array
|
String |
getDescription()
Get names of variables.
|
int |
getNumberColumns()
Return number of columns in the data
|
int |
getNumberRows()
Return number of columns in the data
|
P0D |
getP0D(int column)
Get data as 1D array for a given column
|
P1D |
getP1D(int column1,
int column2)
Convert 2 columns in P1D for plotting.
|
PND |
getPND()
Get data as PND object
|
double[] |
getRow(int index)
Get a row
|
com.jstatcom.ts.TS[] |
getTS()
Return time series as array
|
com.jstatcom.model.JSCSArray |
getVarNames()
Get names of variables
|
void |
readData(String sfile)
Reads many data formats (in ASCII, Gauss, Matlab, Excel) and converts the
data to arrays for further processing.
|
void |
replaceColumn(int column,
double[] d)
Replace a column with anew array.
|
void |
saveData(String outfile,
String type)
Save data in one of the formats.
|
void |
setData(com.jstatcom.model.JSCNArray d)
Set new data.
|
void |
setDescription(String d)
Set new description for data set
|
void |
setPND(PND d)
Set data from PND container
|
void |
setVarNames(com.jstatcom.model.JSCSArray d)
Set variable names.
|
String |
toString()
Convert to a string
|
void |
toTable()
Show the time series data as a table
|
public HStatData(String description)
description - descriptionpublic HStatData()
public HStatData(String description, String sfile)
description - descriptionsfile - input data file including the full path. If it starts from
http: or ftp://, it is assumed that data should be read from
the web location. Otherwise, data will be read from a local
file. In case of URL, the filer will be copied to the local
directory.public void readData(String sfile)
sfile - input data file including the full path. If it starts from
http: or ftp://, it is assumed that data should be read from
the web location. Otherwise, data will be read from a local
file. In case of URL, the filer will be copied to the TMP
directory.public void toTable()
public com.jstatcom.model.JSCNArray getData()
public void setData(com.jstatcom.model.JSCNArray d)
d - input datapublic void setPND(PND d)
public PND getPND()
public String toString()
public com.jstatcom.model.JSCSArray getVarNames()
public void setVarNames(com.jstatcom.model.JSCSArray d)
d - input variable namespublic String getDescription()
public void setDescription(String d)
d - public P0D getP0D(int column)
column - column indexpublic double[] getColumn(int column)
column - index of columnpublic P1D getP1D(int column1, int column2)
column1 - column representing Xcolumn2 - column representing Ypublic void saveData(String outfile, String type)
outfile - Name of the output filetype - A string representing a format. It can be "ASCII" or "TXT",
"Excel", "Matlab","GaussDAT","GaussFMT"public int getNumberColumns()
public int getNumberRows()
public com.jstatcom.ts.TS[] getTS()
public void doc()
public void replaceColumn(int column,
double[] d)
column - column index to be replaced.d - array which will be used to replace the column.public void append(HStatData hs)
hs - data to be appended.public double[] getRow(int index)
index - of this row.jHepWork 3.8 ©