initialization {glmtree}R Documentation

Random initialization of the segmentation

Description

This function randomy initializes the segmentation.

Usage

initialization(K, n)

Arguments

K

The number of segments to start with (maximum number of segments there'll be in the end).

n

The number of observations to draw.

Value

A vector of length n containing a factor with K levels (from 1 to K) drawn with replacement.

Author(s)

Adrien Ehrhardt


[Package glmtree version 0.3.1 Index]