R/cdm_increment_trimming_after_mstep.R

Defines functions cdm_increment_trimming_after_mstep

## File Name: cdm_increment_trimming_after_mstep.R
## File Version: 0.072


cdm_increment_trimming_after_mstep <- function( parm, parm0, max.increment0, type )
{
    c1 <- cdm_trim_increment( increment=parm-parm0, max.increment=max.increment0,
                                        type=2 )
    parm <- parm0 + c1
    max.increment0 <- min( max.increment0, max(abs(parm - parm0)) )
    #--- output
    res <- list( parm=parm, max.increment0=max.increment0)
    return(res)
}

Try the CDM package in your browser

Any scripts or data that you put into this service are public.

CDM documentation built on Aug. 25, 2022, 5:08 p.m.