public abstract class AbstractDataset extends LazyDatasetBase implements Dataset
Modifier and Type | Field and Description |
---|---|
protected AbstractDataset |
base |
protected static char |
BLOCK_CLOSE |
protected static char |
BLOCK_OPEN |
protected Serializable |
odata
The data itself, held in a 1D array, but the object will wrap it to appear as possessing as many dimensions as
wanted
|
protected int |
offset |
protected int |
size |
protected int[] |
stride |
protected Format |
stringFormat |
catchExceptions, logger, metadata, name, shape
ARRAYFLOAT32, ARRAYFLOAT64, ARRAYINT16, ARRAYINT32, ARRAYINT64, ARRAYINT8, ARRAYMUL, BOOL, COMPLEX, COMPLEX128, COMPLEX64, DATE, FLOAT, FLOAT32, FLOAT64, INT, INT16, INT32, INT64, INT8, OBJECT, RGB, STRING
Constructor and Description |
---|
AbstractDataset()
Constructor required for serialisation.
|
Modifier and Type | Method and Description |
---|---|
boolean |
all()
Test if all items are true
|
BooleanDataset |
all(int axis) |
boolean |
any()
Test if any items are true
|
BooleanDataset |
any(int axis) |
int |
argMax(boolean... ignoreInvalids)
Find absolute index of maximum value (in a flattened view)
|
IntegerDataset |
argMax(int axis,
boolean... ignoreInvalids)
Find indices of maximum values along given axis
|
int |
argMin(boolean... ignoreInvalids)
Find absolute index of minimum value (in a flattened view)
|
IntegerDataset |
argMin(int axis,
boolean... ignoreInvalids)
Find indices of minimum values along given axis
|
protected static int |
calcSteps(double start,
double stop,
double step) |
Dataset |
cast(boolean repeat,
int dtype,
int isize)
Cast a dataset
|
<T extends Dataset> |
cast(Class<T> clazz)
Cast a dataset
|
Dataset |
cast(int dtype)
Cast a dataset
|
int |
checkAxis(int axis)
Check that axis is in range [-rank,rank)
|
protected static int |
checkAxis(int rank,
int axis)
Deprecated.
|
void |
checkCompatibility(ILazyDataset g)
This method takes a dataset and checks its shape against the current dataset.
|
abstract AbstractDataset |
clone()
Clone dataset
|
<T extends Dataset> |
copy(Class<T> clazz)
Copy and cast a dataset
|
Dataset |
copy(int dtype)
Copy and cast a dataset
|
protected static void |
copyToView(Dataset orig,
AbstractDataset view,
boolean clone,
boolean cloneMetadata)
Copy fields from original to view
|
long |
count(boolean... ignoreInvalids) |
Dataset |
count(int axis,
boolean... ignoreInvalids) |
static int[] |
createStrides(Dataset a,
int[] offset)
Create a stride array from dataset
|
static int[] |
createStrides(int isize,
int[] shape,
int[] oStride,
int oOffset,
int[] offset)
Create a stride array from dataset
|
static int[] |
createStrides(SliceND slice,
Dataset a,
int[] stride,
int[] offset)
Create a stride array from slice information and a dataset
|
static int[] |
createStrides(SliceND slice,
int isize,
int[] shape,
int[] oStride,
int oOffset,
int[] stride,
int[] offset)
Create a stride array from slice and dataset information
|
boolean |
equals(Object obj) |
protected void |
fillData(Object obj,
int depth,
int[] pos)
Fill dataset from object at depth dimension
|
Dataset |
flatten()
Flatten shape
|
int |
get1DIndex(int... n)
This method calculates the index in the data array that corresponds to
the given n-dimensional position
|
protected int |
get1DIndex(int i) |
protected int |
get1DIndex(int i,
int j) |
protected int |
get1DIndexFromShape(int[] n) |
protected static int |
get1DIndexFromShape(int[] shape,
int[] n) |
BooleanIterator |
getBooleanIterator(Dataset choice)
Get an iterator that visits every item in this dataset where the corresponding item in
choice dataset is true
|
BooleanIterator |
getBooleanIterator(Dataset choice,
boolean value)
Get an iterator that visits every item in this dataset where the corresponding item in
choice dataset is given by value
|
Dataset |
getBroadcastView(int... broadcastShape) |
Serializable |
getBuffer() |
protected abstract int |
getBufferLength() |
Dataset |
getBy1DIndex(IntegerDataset index)
This is modelled after the NumPy get item with an index dataset
|
Dataset |
getByBoolean(Dataset selection)
This is modelled after the NumPy get item with a condition specified by a boolean dataset
|
Dataset |
getByIndexes(Object... indexes)
This is modelled after the NumPy get item with an array of indexing objects
|
Class<?> |
getElementClass() |
int |
getElementsPerItem() |
double |
getError()
Get the error for the first item.
|
double |
getError(int... pos)
Get the error for a given position.
|
double |
getError(int i)
Get the error for given position.
|
double |
getError(int i,
int j)
Get the error for given position.
|
double[] |
getErrorArray(int... pos)
Get the error values for a single point in the dataset
|
double[] |
getErrorArray(int i)
Get the error values for given position
|
double[] |
getErrorArray(int i,
int j)
Get the error values for given position
|
Dataset |
getErrorBuffer()
Get the (un-broadcasted) dataset that backs the (squared) error data
|
Dataset |
getErrors()
Get the errors, if any.
|
protected int |
getFirst1DIndex() |
IntegerDataset |
getIndices()
Generate an index dataset for current dataset
|
protected Dataset |
getInternalSquaredError() |
int |
getItemBytes() |
IndexIterator |
getIterator() |
IndexIterator |
getIterator(boolean withPosition) |
static int |
getMaxLineLength() |
protected static ConcurrentMap<Class<? extends MetadataType>,List<MetadataType>> |
getMetadataMap(Dataset a,
boolean clone) |
String |
getName() |
int |
getNbytes() |
int[] |
getNDPosition(int n)
This method calculates the n-dimensional position in the dataset of
the given index in the data array
|
int |
getOffset() |
PositionIterator |
getPositionIterator(int... axes) |
int |
getRank()
The rank (or number of dimensions/indices) of the dataset can be zero for a zero-rank
(single-valued) dataset
|
Dataset |
getRealPart() |
Dataset |
getRealView() |
int[] |
getShape()
The shape (or array of lengths for each dimension) of the dataset can be empty for zero-rank
datasets
|
int[] |
getShapeRef()
The shape (or array of lengths for each dimension) of the dataset can be empty for zero-rank
datasets and null for null datasets
|
int |
getSize()
The size of the dataset is the number of items in the array
|
Dataset |
getSlice(IMonitor monitor,
int[] start,
int[] stop,
int[] step)
Get a slice of the dataset.
|
Dataset |
getSlice(IMonitor monitor,
Slice... slice)
Get a slice of the dataset.
|
Dataset |
getSlice(IMonitor monitor,
SliceND slice)
Get a slice of the dataset.
|
Dataset |
getSlice(int[] start,
int[] stop,
int[] step)
Get a slice of the dataset.
|
Dataset |
getSlice(Slice... slice)
Get a slice of the dataset.
|
abstract AbstractDataset |
getSlice(SliceIterator iterator)
Get a slice of the dataset.
|
Dataset |
getSlice(SliceND slice)
Get a slice of the dataset.
|
IndexIterator |
getSliceIterator(int[] start,
int[] stop,
int[] step) |
IndexIterator |
getSliceIterator(SliceND slice) |
SliceIterator |
getSliceIteratorFromAxes(int[] pos,
boolean[] axes)
Get a slice iterator that is defined by a starting position and a set of axes to include
|
Dataset |
getSliceView(int[] start,
int[] stop,
int[] step)
Get a slice of the dataset.
|
Dataset |
getSliceView(Slice... slice)
Get a slice of the dataset.
|
Dataset |
getSliceView(SliceND slice)
Get a slice of the dataset.
|
protected StatisticsMetadata<Number> |
getStats() |
int[] |
getStrides() |
protected StatisticsMetadata<String> |
getStringStats() |
Dataset |
getTransposedView(int... axes)
Permute copy of dataset's axes so that given order is old order:
|
abstract AbstractDataset |
getView(boolean deepCopyMetadata) |
boolean |
hasFloatingPointElements() |
int |
hashCode() |
Dataset |
ifloorDivide(Object o)
In-place floor division with object o
|
boolean |
isCompatibleWith(ILazyDataset g)
This method takes a dataset and checks its shape against the current dataset.
|
boolean |
isComplex() |
Number |
max(boolean... ignoreInvalids) |
Dataset |
max(int axis,
boolean... ignoreInvalids) |
Object |
mean(boolean... ignoreInvalids) |
Dataset |
mean(int axis,
boolean... ignoreInvalids) |
Number |
min(boolean... ignoreInvalids) |
Dataset |
min(int axis,
boolean... ignoreInvalids) |
void |
overrideInternal(Serializable buffer,
int... shape)
Set the buffer that backs the dataset and its shape
|
Number |
peakToPeak(boolean... ignoreInvalids) |
Dataset |
peakToPeak(int axis,
boolean... ignoreInvalids) |
Object |
product(boolean... ignoreInvalids) |
Dataset |
product(int axis,
boolean... ignoreInvalids) |
Dataset |
reshape(int... shape)
Returns new dataset with new shape but old data if possible, otherwise a copy is made
|
double |
residual(Object o)
Calculate residual of dataset with object o
See
Dataset.residual(Object o, boolean ignoreNaNs) with ignoreNaNs = false |
double |
residual(Object o,
boolean ignoreNaNs)
Calculate residual of dataset with object o
|
double |
rootMeanSquare(boolean... ignoreInvalids) |
Dataset |
rootMeanSquare(int axis,
boolean... ignoreInvalids) |
protected abstract void |
setData()
Set aliased data as base data
|
void |
setErrorBuffer(Serializable buffer)
Set a copy of the buffer that backs the (squared) error data
|
protected abstract void |
setItemDirect(int dindex,
int sindex,
Object src)
Set item from compatible dataset in a direct and speedy way.
|
static void |
setMaxLineLength(int maxLineLength)
Set maximum line length for toString() method
|
void |
setName(String name) |
void |
setShape(int... shape)
Set a compatible shape for dataset.
|
Dataset |
setSlice(Object obj,
int[] start,
int[] stop,
int[] step)
This is modelled after the NumPy array slice
|
Dataset |
setSlice(Object obj,
Slice... slice)
This is modelled after the NumPy array slice
|
Dataset |
setSlice(Object obj,
SliceND slice)
This is modelled after the NumPy array slice
|
void |
setStringFormat(Format format)
Set string output format
|
Dataset |
squeeze()
Remove dimensions of 1 in shape of the dataset
|
Dataset |
squeeze(boolean onlyFromEnds)
Remove dimensions of 1 in shape of the dataset from ends only if true
|
Dataset |
squeezeEnds()
Remove dimensions of 1 from ends of shape of the dataset
|
double |
stdDeviation()
Standard deviation is square root of the variance
|
double |
stdDeviation(boolean isWholePopulation,
boolean... ignoreInvalids)
Standard deviation is square root of the variance
|
Dataset |
stdDeviation(int axis)
Standard deviation is square root of the variance
|
Dataset |
stdDeviation(int axis,
boolean isWholePopulation,
boolean... ignoreInvalids)
Standard deviation is square root of the variance
|
Object |
sum(boolean... ignoreInvalids) |
Dataset |
sum(int axis,
boolean... ignoreInvalids) |
Dataset |
swapAxes(int axis1,
int axis2)
Swap two axes in dataset
|
Dataset |
synchronizedCopy()
This is a synchronized version of the clone method
|
String |
toString() |
String |
toString(boolean showData) |
Dataset |
transpose(int... axes)
|
double |
variance() |
double |
variance(boolean isWholePopulation,
boolean... ignoreInvalids)
The sample variance can be calculated in two ways: if the dataset is considered as the
entire population then the sample variance is simply the second central moment:
|
Dataset |
variance(int axis) |
Dataset |
variance(int axis,
boolean isWholePopulation,
boolean... ignoreInvalids) |
addMetadata, checkPermutatedAxes, clearMetadata, copyMetadata, copyMetadata, createFromSerializable, dirtyMetadata, findMetadataTypeSubInterfaces, getDType, getErrorMetadata, getFirstMetadata, getMetadata, getMetadata, hasErrors, reshapeMetadata, restoreMetadata, setDirty, setErrors, setMetadata, sliceMetadata, transposeMetadata
finalize, getClass, notify, notifyAll, wait, wait, wait
containsInfs, containsInvalidNumbers, containsNans, copyItemsFromAxes, fill, fillDataset, getBoolean, getBoolean, getBoolean, getByte, getByte, getByte, getDouble, getDouble, getDouble, getDType, getElementBooleanAbs, getElementDoubleAbs, getElementLongAbs, getFloat, getFloat, getFloat, getInt, getInt, getInt, getLong, getLong, getLong, getObject, getObject, getObject, getObjectAbs, getShort, getShort, getShort, getString, getString, getString, getStringAbs, getUniqueItems, iadd, idivide, ifloor, imultiply, ipower, iremainder, isubtract, residual, set, set, set, setBy1DIndex, setByBoolean, setByIndexes, setDirty, setItemsOnAxes, setObjectAbs, setSlice, sort
getBoolean, getByte, getDouble, getFloat, getInt, getLong, getMetadata, getObject, getShort, getString, maxPos, minPos, resize, set
addMetadata, clearMetadata, hasErrors, setErrors, setMetadata
getFirstMetadata, getMetadata
protected int size
protected transient AbstractDataset base
protected int[] stride
protected int offset
protected Serializable odata
protected Format stringFormat
protected static final char BLOCK_OPEN
protected static final char BLOCK_CLOSE
public AbstractDataset()
protected abstract void setData()
public Dataset synchronizedCopy()
Dataset
synchronizedCopy
in interface Dataset
public boolean equals(Object obj)
equals
in class LazyDatasetBase
public int hashCode()
hashCode
in class LazyDatasetBase
public abstract AbstractDataset clone()
ILazyDataset
clone
in interface Dataset
clone
in interface IDataset
clone
in interface ILazyDataset
clone
in class LazyDatasetBase
public void setStringFormat(Format format)
IDataset
setStringFormat
in interface IDataset
public Dataset copy(int dtype)
Dataset
public <T extends Dataset> T copy(Class<T> clazz)
Dataset
public <T extends Dataset> T cast(Class<T> clazz)
Dataset
public Dataset cast(boolean repeat, int dtype, int isize)
Dataset
public abstract AbstractDataset getView(boolean deepCopyMetadata)
protected static void copyToView(Dataset orig, AbstractDataset view, boolean clone, boolean cloneMetadata)
orig
- view
- clone
- if true, then clone everything but bulk datacloneMetadata
- if true, clone metadataprotected static ConcurrentMap<Class<? extends MetadataType>,List<MetadataType>> getMetadataMap(Dataset a, boolean clone)
public IntegerDataset getIndices()
Dataset
getIndices
in interface Dataset
public Dataset getTransposedView(int... axes)
IDataset
axisPerm = (p(0), p(1),...) => newdata(n(0), n(1),...) = olddata(o(0), o(1), ...) such that n(i) = o(p(i)) for all iI.e. for a 3D dataset (1,0,2) implies the new dataset has its 1st dimension running along the old dataset's 2nd dimension and the new 2nd is the old 1st. The 3rd dimension is left unchanged.
getTransposedView
in interface Dataset
getTransposedView
in interface IDataset
getTransposedView
in interface ILazyDataset
axes
- if zero length then axes order reversedpublic Dataset swapAxes(int axis1, int axis2)
Dataset
protected void fillData(Object obj, int depth, int[] pos)
obj
- depth
- pos
- positionpublic IndexIterator getIterator(boolean withPosition)
getIterator
in interface Dataset
withPosition
- set true if position is neededpublic IndexIterator getIterator()
getIterator
in interface Dataset
public PositionIterator getPositionIterator(int... axes)
getPositionIterator
in interface Dataset
axes
- axes to omit from iteratorpublic IndexIterator getSliceIterator(int[] start, int[] stop, int[] step)
getSliceIterator
in interface Dataset
start
- specifies the starting indexesstop
- specifies the stopping indexes (nb, these are not included in the slice)step
- specifies the steps in the slicepublic IndexIterator getSliceIterator(SliceND slice)
getSliceIterator
in interface Dataset
slice
- public SliceIterator getSliceIteratorFromAxes(int[] pos, boolean[] axes)
Dataset
getSliceIteratorFromAxes
in interface Dataset
axes
- to includepublic BooleanIterator getBooleanIterator(Dataset choice)
Dataset
getBooleanIterator
in interface Dataset
public BooleanIterator getBooleanIterator(Dataset choice, boolean value)
Dataset
getBooleanIterator
in interface Dataset
public Dataset getByBoolean(Dataset selection)
Dataset
getByBoolean
in interface Dataset
selection
- a boolean dataset of same shape to use for selecting itemspublic Dataset getBy1DIndex(IntegerDataset index)
Dataset
getBy1DIndex
in interface Dataset
index
- an integer datasetpublic Dataset getByIndexes(Object... indexes)
Dataset
getByIndexes
in interface Dataset
indexes
- an array of integer dataset, boolean dataset, slices or null entries (same as
full slices)public Class<?> getElementClass()
getElementClass
in interface ILazyDataset
getElementClass
in class LazyDatasetBase
public boolean hasFloatingPointElements()
hasFloatingPointElements
in interface Dataset
public int getElementsPerItem()
getElementsPerItem
in interface ILazyDataset
public int getItemBytes()
getItemBytes
in interface IDataset
public String getName()
getName
in interface INameable
getName
in class LazyDatasetBase
public void setName(String name)
setName
in interface INameable
setName
in class LazyDatasetBase
public int getSize()
ILazyDataset
getSize
in interface ILazyDataset
public int[] getShape()
ILazyDataset
getShape
in interface ILazyDataset
getShape
in class LazyDatasetBase
public int getRank()
ILazyDataset
getRank
in interface ILazyDataset
getRank
in class LazyDatasetBase
public int getNbytes()
public void setShape(int... shape)
ILazyDataset
setShape
in interface ILazyDataset
public int[] getShapeRef()
Dataset
getShapeRef
in interface Dataset
public int getOffset()
public int[] getStrides()
getStrides
in interface Dataset
public Serializable getBuffer()
public void overrideInternal(Serializable buffer, int... shape)
Dataset
This is very, very dangerous. Please use carefully
overrideInternal
in interface Dataset
buffer
- (can be null to leave unchanged)shape
- (can be null to leave unchanged)public static int[] createStrides(Dataset a, int[] offset)
a
- datasetoffset
- output offsetpublic static int[] createStrides(int isize, int[] shape, int[] oStride, int oOffset, int[] offset)
isize
- shape
- oStride
- original strideoOffset
- original offset (only used if there is an original stride)offset
- output offsetpublic static int[] createStrides(SliceND slice, Dataset a, int[] stride, int[] offset)
slice
- a
- datasetstride
- output strideoffset
- output offsetpublic static int[] createStrides(SliceND slice, int isize, int[] shape, int[] oStride, int oOffset, int[] stride, int[] offset)
slice
- isize
- shape
- oStride
- original strideoOffset
- original offset (only used if there is an original stride)stride
- output strideoffset
- output offsetpublic Dataset getBroadcastView(int... broadcastShape)
getBroadcastView
in interface Dataset
public Dataset getSliceView(int[] start, int[] stop, int[] step)
IDataset
getSliceView
in interface Dataset
getSliceView
in interface IDataset
getSliceView
in interface ILazyDataset
start
- specifies the starting indexes (can be null for origin)stop
- specifies the stopping indexes (can be null for end)step
- specifies the steps in the slice (can be null for unit steps)public Dataset getSliceView(Slice... slice)
IDataset
getSliceView
in interface Dataset
getSliceView
in interface IDataset
getSliceView
in interface ILazyDataset
slice
- an array of slice objects (the array can be null or contain nulls)public Dataset getSliceView(SliceND slice)
getSliceView
in interface Dataset
getSliceView
in interface IDataset
getSliceView
in interface ILazyDataset
slice
- protected int getFirst1DIndex()
public int get1DIndex(int... n)
Dataset
get1DIndex
in interface Dataset
n
- the integer array specifying the n-D positionprotected int get1DIndex(int i)
i
- protected int get1DIndex(int i, int j)
i
- j
- protected int get1DIndexFromShape(int[] n)
protected static int get1DIndexFromShape(int[] shape, int[] n)
public int[] getNDPosition(int n)
Dataset
getNDPosition
in interface Dataset
n
- The index in the arrayprotected abstract int getBufferLength()
public int checkAxis(int axis)
Dataset
@Deprecated protected static int checkAxis(int rank, int axis)
public static void setMaxLineLength(int maxLineLength)
maxLineLength
- public static int getMaxLineLength()
public Dataset squeezeEnds()
ILazyDataset
squeezeEnds
in interface Dataset
squeezeEnds
in interface IDataset
squeezeEnds
in interface ILazyDataset
public Dataset squeeze()
IDataset
public Dataset squeeze(boolean onlyFromEnds)
IDataset
public boolean isCompatibleWith(ILazyDataset g)
Dataset
isCompatibleWith
in interface Dataset
g
- The dataset to be comparedpublic void checkCompatibility(ILazyDataset g) throws IllegalArgumentException
Dataset
checkCompatibility
in interface Dataset
g
- The dataset to be comparedIllegalArgumentException
- This will be thrown if there is a problem with the compatibilitypublic Dataset reshape(int... shape)
Dataset
protected static int calcSteps(double start, double stop, double step)
start
- stop
- step
- public boolean isComplex()
public Dataset getRealPart()
getRealPart
in interface Dataset
public Dataset getRealView()
getRealView
in interface Dataset
public Dataset getSlice(int[] start, int[] stop, int[] step)
ILazyDataset
getSlice
in interface Dataset
getSlice
in interface IDataset
getSlice
in interface ILazyDataset
start
- specifies the starting indexes (can be null for origin)stop
- specifies the stopping indexes (can be null for end)step
- specifies the steps in the slice (can be null for unit steps)public Dataset getSlice(Slice... slice)
ILazyDataset
public Dataset getSlice(IMonitor monitor, Slice... slice)
ILazyDataset
getSlice
in interface Dataset
getSlice
in interface ILazyDataset
slice
- an array of slice objects (the array can be null or contain nulls)public Dataset getSlice(IMonitor monitor, SliceND slice)
ILazyDataset
getSlice
in interface Dataset
getSlice
in interface ILazyDataset
slice
- an n-D slicepublic Dataset getSlice(IMonitor monitor, int[] start, int[] stop, int[] step)
ILazyDataset
getSlice
in interface Dataset
getSlice
in interface ILazyDataset
start
- specifies the starting indexes (can be null for origin)stop
- specifies the stopping indexes (can be null for end)step
- specifies the steps in the slice (can be null for unit steps)public Dataset getSlice(SliceND slice)
public abstract AbstractDataset getSlice(SliceIterator iterator)
iterator
- Slice iteratorpublic Dataset setSlice(Object obj, SliceND slice)
Dataset
public Dataset setSlice(Object obj, int[] start, int[] stop, int[] step)
Dataset
setSlice
in interface Dataset
obj
- specifies the object used to set the specified slicestart
- specifies the starting indexesstop
- specifies the stopping indexes (nb, these are not included in the slice)step
- specifies the steps in the slicepublic Dataset setSlice(Object obj, Slice... slice)
Dataset
public BooleanDataset all(int axis)
public BooleanDataset any(int axis)
public Dataset ifloorDivide(Object o)
Dataset
ifloorDivide
in interface Dataset
public double residual(Object o)
Dataset
Dataset.residual(Object o, boolean ignoreNaNs)
with ignoreNaNs = falsepublic double residual(Object o, boolean ignoreNaNs)
Dataset
protected StatisticsMetadata<Number> getStats()
protected StatisticsMetadata<String> getStringStats()
public Dataset max(int axis, boolean... ignoreInvalids)
max
in interface Dataset
ignoreInvalids
- - Can be null, empty, or one or more booleans. By default, all booleans
are false. If the first boolean is true, will ignore NaNs and ignore infinities. Use the second
boolean to ignore infinities separately.public Number min(boolean... ignoreInvalids)
min
in interface IDataset
ignoreInvalids
- - see IDataset.max(boolean...)
public Dataset min(int axis, boolean... ignoreInvalids)
min
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public int argMax(boolean... ignoreInvalids)
Dataset
argMax
in interface Dataset
ignoreInvalids
- - see IDataset.max(boolean...)
public IntegerDataset argMax(int axis, boolean... ignoreInvalids)
Dataset
argMax
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public int argMin(boolean... ignoreInvalids)
Dataset
argMin
in interface Dataset
ignoreInvalids
- - see IDataset.max(boolean...)
public IntegerDataset argMin(int axis, boolean... ignoreInvalids)
Dataset
argMin
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public Number peakToPeak(boolean... ignoreInvalids)
peakToPeak
in interface Dataset
ignoreInvalids
- - see IDataset.max(boolean...)
public Dataset peakToPeak(int axis, boolean... ignoreInvalids)
peakToPeak
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public long count(boolean... ignoreInvalids)
count
in interface Dataset
ignoreInvalids
- - see IDataset.max(boolean...)
public Dataset count(int axis, boolean... ignoreInvalids)
count
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public Object sum(boolean... ignoreInvalids)
sum
in interface Dataset
ignoreInvalids
- - see IDataset.max(boolean...)
public Dataset sum(int axis, boolean... ignoreInvalids)
sum
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public Object product(boolean... ignoreInvalids)
product
in interface Dataset
ignoreInvalids
- - see IDataset.max(boolean...)
public Dataset product(int axis, boolean... ignoreInvalids)
product
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public Object mean(boolean... ignoreInvalids)
mean
in interface IDataset
ignoreInvalids
- - see IDataset.max(boolean...)
public Dataset mean(int axis, boolean... ignoreInvalids)
mean
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public double variance()
variance
in interface Dataset
with isWholePopulation = false
public double variance(boolean isWholePopulation, boolean... ignoreInvalids)
Dataset
sum((x_i - m)^2)/N where {x_i} are set of N population values and m is the mean m = sum(x_i)/NOtherwise, if the dataset is a set of samples (with replacement) from the population then
sum((x_i - m)^2)/(N-1) where {x_i} are set of N sample values and m is the unbiased estimate of the mean m = sum(x_i)/NNote that the second definition is also the unbiased estimator of population variance.
variance
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
public Dataset variance(int axis)
variance
in interface Dataset
with isWholePopulation = false
public Dataset variance(int axis, boolean isWholePopulation, boolean... ignoreInvalids)
variance
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
with isWholePopulation = false
public double stdDeviation()
Dataset
stdDeviation
in interface Dataset
with isWholePopulation = false
public double stdDeviation(boolean isWholePopulation, boolean... ignoreInvalids)
Dataset
stdDeviation
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
Dataset.variance(boolean, boolean...)
public Dataset stdDeviation(int axis)
Dataset
stdDeviation
in interface Dataset
with isWholePopulation = false
public Dataset stdDeviation(int axis, boolean isWholePopulation, boolean... ignoreInvalids)
Dataset
stdDeviation
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
with isWholePopulation = false
public double rootMeanSquare(boolean... ignoreInvalids)
rootMeanSquare
in interface Dataset
ignoreInvalids
- - see IDataset.max(boolean...)
public Dataset rootMeanSquare(int axis, boolean... ignoreInvalids)
rootMeanSquare
in interface Dataset
ignoreInvalids
- - see Dataset.max(int, boolean...)
protected abstract void setItemDirect(int dindex, int sindex, Object src)
dindex
- sindex
- src
- is the source data bufferpublic Dataset getErrors()
ILazyDataset
getErrors
in interface Dataset
getErrors
in interface IDataset
getErrors
in interface ILazyDataset
getErrors
in class LazyDatasetBase
public double getError()
Dataset
public double getError(int i)
Dataset
public double getError(int i, int j)
Dataset
public double getError(int... pos)
IDataset
public double[] getErrorArray(int i)
Dataset
getErrorArray
in interface Dataset
public double[] getErrorArray(int i, int j)
Dataset
getErrorArray
in interface Dataset
public double[] getErrorArray(int... pos)
IDataset
getErrorArray
in interface IDataset
pos
- of the point to be referencedprotected Dataset getInternalSquaredError()
public Dataset getErrorBuffer()
Dataset
getErrorBuffer
in interface Dataset
public void setErrorBuffer(Serializable buffer)
setErrorBuffer
in interface Dataset
buffer
- can be null, anything that can be used to create a DoubleDataset or CompoundDoubleDatasetCopyright © 2014–2017 Eclipse Foundation. All rights reserved.