TnT_Split

scalation.mathstat.TnT_Split
object TnT_Split

The TnT_Split object provides methods for splitting datasets into testing-sets and training-sets.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
TnT_Split.type

Members list

Value members

Concrete methods

def apply(xy: MatrixD, idx: IndexedSeq[Int]): (MatrixD, MatrixD)

Split the dataset given as a combined data-response matrix into a testing-set and training-set based on the given indices.

Split the dataset given as a combined data-response matrix into a testing-set and training-set based on the given indices.

Value parameters

idx

the indices for the testing-set

xy

the combined data-response matrix

Attributes

def apply(x: MatrixD, y: VectorD, idx: Set[Int]): (MatrixD, MatrixD, VectorD, VectorD)

Split the dataset given as a data matrix and a response vector into a testing-set and training-set based on the given indices.

Split the dataset given as a data matrix and a response vector into a testing-set and training-set based on the given indices.

Value parameters

idx

the set of indices for the testing-set

x

the input/data matrix (for some models this may be null => return (null, null)

y

the output/response vector

Attributes

See also

scalation.modeling.Predictor

def apply(x: MatrixD, y: VectorD, idx: IndexedSeq[Int]): (MatrixD, MatrixD, VectorD, VectorD)
def apply(x: MatrixD, y: VectorI, idx: IndexedSeq[Int]): (MatrixD, MatrixD, VectorI, VectorI)

Split the dataset given as a data matrix and an integer-valued response vector into a testing-set and training-set based on the given indices.

Split the dataset given as a data matrix and an integer-valued response vector into a testing-set and training-set based on the given indices.

Value parameters

idx

the indices for the testing-set

x

the input/data matrix (for some models this may be null => return (null, null)

y

the integer-valued output/response vector

Attributes

See also

scalation.modelingq.classifying.Classifier

def apply(x: MatrixD, y: MatrixD, idx: IndexedSeq[Int]): (MatrixD, MatrixD, MatrixD, MatrixD)

Split the dataset given as a data matrix and a response matrix into a testing-set and training-set based on the given indices.

Split the dataset given as a data matrix and a response matrix into a testing-set and training-set based on the given indices.

Value parameters

idx

the indices for the testing-set

x

the input/data matrix

y

the output/response matrix

Attributes

See also

scalation.modeling.neuralnet.PredictorMV

def makePermGen(limit: Int, stream: Int): PermutedVecI

Make a permutation generator for integers from 0 until limit.

Make a permutation generator for integers from 0 until limit.

Value parameters

limit

the upper limit of integers (exclusive)

stream

the random number stream to use

Attributes

def testIndices(permGen: PermutedVecI, n_test: Int, rando: Boolean): IndexedSeq[Int]

Return the indices for the test-set.

Return the indices for the test-set.

Value parameters

n_test

the size of test-set

rando

whether to select indices randomly or in blocks (defaults to true)

Attributes

def testIndices2(permGen: PermutedVecI, n_test: Int, rando: Boolean): Set[Int]