Jeff Harring wrote:
>
> I am looking for R code to be able to fit a linear-linear piecewise
> model with person-specific changepoint. I have searched the web, but
> have not been able to locate any code.
>
> ..
> I would appreciate any advice on this code or guidance as to where to
> search
I am looking for R code to be able to fit a linear-linear piecewise
model with person-specific changepoint. I have searched the web, but
have not been able to locate any code.
Below is my attempt at some code:
chgpt = function(a1,a2,a3,gam,wave){
yht=numeric(10)
y1=(wave <= gam)*(a1+(a2*wave))
2 matches
Mail list logo