set_parms: Under construction: Generate random starting values for a...

View source: R/hawkes_em_functions.R

set_parmsR Documentation

Under construction: Generate random starting values for a Hawkes process.

Description

For a given pp object with a given kernel_type, generate random starting values for EM algorithm. Currently only implemented for "dgamma". To Do: implement other kernels, generate parameters that follow equality constraints.

Usage

set_parms(pp_obj, kernel_type = "dgamma", constraints = NULL)

Arguments

pp_obj

a pp object.

kernel_type

currently only implemented for "dgamma".

constraints

currently not implemented.

Value

A named list of numeric arrays with components c("mu", "alpha", "k_parm1", "k_parm2") defined as follows. Let n_margins denote the attr(pp_obj, "n_margins"). Then "mu" is the n_margins-vector of baseline parameters; "alpha" is the n_margins-by-n_margins matrix of intensity parameters; "k_parm1" is the n_margins-by-n_margins matrix containing the first arg to the response kernels; "k_parm2" is the n_margins-by-n_margins matrix containing the second arg to the response kernels.


peterhalpin/hawkes documentation built on July 2, 2023, 1:04 p.m.