random_population | R Documentation |
Randomly generate the individuals' chromosomes (changepoint confirgurations) to construct the first generation population.
random_population(popsize, prange, N, minDist, Pb, mmax, lmax)
popsize |
An integer represents the number of individual in each population for GA (or subpopulation for IslandGA). |
prange |
Default is |
N |
The length of time series. |
minDist |
The minimum length between two adjacent changepoints. |
Pb |
Same as |
mmax |
The maximum possible number of changepoints in the data set. |
lmax |
The maximum possible length of the chromosome representation. |
The default population initialization uses selectTau
to
select the chromosome for the first generation population. Each column from
the produced population matrix represent an chromosome of an individual.
The first element of every chromosome represent the number of changepoints
and the last non-zero element always equal to the length of time series
plus one (N+1).
A matrix that contains each individual's chromosome.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.