[R] Breakpoints for multiple variables using Segmented

vito muggeo vmuggeo at dssm.unipa.it
Fri Jan 20 11:29:09 CET 2006

Dear Matthew,
Currently segmented() performs multiple (say L>1) estimation of 
breakpoints in GLM, namely:

1)L breakpoints for the same variable x, e.g.:
segmented(obj.glm, Z=x, psi=c(psi1,psi2,psi3))

2)L breakpoints for L explanatory `segmented' variables, e.g.:
segmented(obj.glm, Z=cbind(x1,x2,x3), psi=c(psi1,psi2,psi3))
In this case it is assumed that each x has just one breakpoint (psi1 for 
x1, psi2 for x2, and so on). This is, actually , a limit - I know. 
Currently I have no time :-(, but sooner or later I should update the 

Hope this helps,

Matthew Betts wrote:
> Hi all,
> I am using the package “Segmented” to estimate logistic regression models
> with unknown breakpoints (see Muggeo 2003 Statistics in Medicine
> 22:3055-3071). In the documentation it suggests that it might be possible to
> include several variables with breakpoints in the same model: “Z = a vector
> or a matrix meaning the (continuous) explanatory variable(s) having
> segmented relationships with the response”. However, the syntax for
> including multiple “Z” and “psi” (“starting values for the break-point(s)”)
> is not stated. Does anyone have any suggestions?
> Here is an example of correct code for detecting single breakpoint:
> model.seg<-segmented.glm(obj = model.glm, Z = predictor_variable, psi = 2 ,
> it.max = 50)
> Thanks very much for your help.
> Matthew G. Betts, Ph.D.
> NB Cooperative Fish and Wildlife Research Unit
> Faculty of Forestry and Environmental Management
> University of New Brunswick 
> UNB Tweedale Centre
> Hugh John Flemming Forestry Complex
> 1350 Regent St., Fredericton, N.B.
> E3C 2G6
> (506) 447-3408
> http://www.unb.ca/web/acwern/people/mbetts/mbetts.htm
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html

Vito M.R. Muggeo
Dip.to Sc Statist e Matem `Vianelli'
Università di Palermo
viale delle Scienze, edificio 13
90128 Palermo - ITALY
tel: 091 6626240
fax: 091 485726/485612

More information about the R-help mailing list