inst/non_lin_models/Mod_loga.R

# Logarithmic MODEL (GLEASON 1922)
model <- list(
    name=c("Logarithmic"),
    formula=expression(S==c+z*log(A)),
    exp=expression(c+z*log(A)),
    shape="convex",
    asymp=function(pars)FALSE,
    #limits for parameters
    parLim = c("R","R"),
    custStart=function(data)c(5,.25),
    #initials values function
    init=function(data){
      semilog.data = data.frame(log(data$A),data$S)
      names(semilog.data)=c("A","S")
      par=stats::lm(S~A,semilog.data)$coefficients
      names(par)=c("c","z")
      par
    }
)
txm676/mmSAR2 documentation built on Nov. 21, 2024, 5:03 a.m.