Description Usage Arguments Value Examples
Applies a nonlinear regression on a specific dataset.
1 |
xx |
quantity on the x axis (e.g. duration). Must be a vector of numerics |
pp |
quantity on the y axis (e.g. proportion of long responses). Must be a vector of numerics AND of the same length as xx. |
type |
string expliciting which of three available fitting functions will be used. "CG" for cumulative Gaussian, "LN" for lognormal and "PL" for pseudologistic. |
getPred |
Function that returns the predicted value. |
residFun |
Function that returns the residuals. |
fnJacob |
Function that returns the jacobian of the function to be fitted. |
fnStart |
Function that returns the starting parameters. |
control |
a control list for the non linear regression. See |
a psyFitted-class
object containing the fitted data.
1 2 3 4 5 6 7 | data("exampleData",package="nlregVL.R")
setkey(exampleData,Sub)
xx<-exampleData[J("TP01")][,Duration]
nbb1<-exampleData[J("TP01"),Nb1]
nbb3<-exampleData[J("TP01"),Nb3]
pp<-nbb3/(nbb1+nbb3)
result<-nlregVL::doPsyFit(xx = xx,pp = pp)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.