FPI: Fixed Point Iteration

Description Usage Arguments Details Value Examples

View source: R/FPI.R

Description

Run fixed point iteration.

Usage

1
FPI(data, par, var, new, max_iter = 400)

Arguments

data

The CNV dataset (see load_data)

par

The parameter used for fixed point method. (see set_par)

var

The current value for all variables (see init_var)

new

The initial loss value

max_iter

The maximum number of iterations that the method is allowed to run

Details

This is the main part for WGD analysis. This function uses the fixed point method to iteratively calculate the optimal value for all variables and store the loss for each iteration in an array.

It runs until the improvement in loss is sufficiently small or the number of iteration reaches the max defined by user. It then returns a list, containing two objects: var, which is a list for the optimal value of the variables; loss_array, which is an array of loss values.

Value

list of the optimal values for variables and the loss for each iteration

Examples

1
FPI_result=FPI(wkdata,CNV_par,common_var,init_loss)

yun-feng/WGDAP documentation built on Nov. 5, 2019, 1:22 p.m.