There is a function called arrows() which is an .Internal function. How difficult is it to modify that function to return the xy coordinates for the line "segments" that make up the arrowhead? Brandon Chasco University of Washington ph (206) 221-6768
On Wed, 23 Aug 2006, B. Chasco wrote:> There is a function called arrows() which is an .Internal function. How > difficult is it to modify that function to return the xy coordinates for > the line "segments" that make up the arrowhead?That depends on your 'core competencies'. You have the source, which is in file src/main/plot.c (and GArrow in src/main/graphics.c). I am not sure I understand your question, as arrows() is plural and draws multiple arrows with 0/1/2 heads each. Also, the 'xy coordinates' are to be in which coordinate system, and you do realize that the sizes in user coordinates change if you resize the plot? -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595
You could also look at p.arrows in sfsmisc package which is entirely in R. On 8/23/06, B. Chasco <bchasco at u.washington.edu> wrote:> There is a function called arrows() which is an .Internal function. How > difficult is it to modify that function to return the xy coordinates for > the line "segments" that make up the arrowhead? > > Brandon Chasco > University of Washington > ph (206) 221-6768 > > ______________________________________________ > 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 > and provide commented, minimal, self-contained, reproducible code. >