Re: [R] drawing arrows

2009-05-16 Thread Jim Lemon

christophe dutang wrote:

Hi,

I would like to draw arrows in a classic 2D plot. Which package should I
use? is there R base functions that do job?

On google, I could not find any useful discussion about this topic, except a
link to the function 'grid.arrows' of the grid package.

My problem is I would like to draw arrows at the edge of circles drawn by
the 'symbols' function. Maybe there is already a dedicated function for
this?

Any help is appreciated.

Christophe



  

Hi Christophe,
If you are trying to do what I think you are trying to do, consider 
drawing the arrow first, with the starting point at the center of the 
circle, then draw the circle with a fill color the same as the 
background. This should give you a circle with a nice radial arrow 
emerging from the edge.


Jim

__
R-help@r-project.org 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.


Re: [R] drawing arrows

2009-05-15 Thread Duncan Murdoch

On 5/15/2009 12:43 PM, christophe dutang wrote:

Hi,

I would like to draw arrows in a classic 2D plot. Which package should I
use? is there R base functions that do job?

On google, I could not find any useful discussion about this topic, except a
link to the function 'grid.arrows' of the grid package.

My problem is I would like to draw arrows at the edge of circles drawn by
the 'symbols' function. Maybe there is already a dedicated function for
this?

Any help is appreciated.



See ?arrows.

Duncan Murdoch

__
R-help@r-project.org 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.


[R] drawing arrows

2009-05-15 Thread christophe dutang
Hi,

I would like to draw arrows in a classic 2D plot. Which package should I
use? is there R base functions that do job?

On google, I could not find any useful discussion about this topic, except a
link to the function 'grid.arrows' of the grid package.

My problem is I would like to draw arrows at the edge of circles drawn by
the 'symbols' function. Maybe there is already a dedicated function for
this?

Any help is appreciated.

Christophe



-- 
Christophe DUTANG
Ph. D. student at ISFA

[[alternative HTML version deleted]]

__
R-help@r-project.org 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.


Re: [R] drawing arrows

2009-05-15 Thread Greg Snow
Duncan mentioned the arrows function, which may do everything you want.  But, 
also look at the my.symbols function in the TeachingDemos package for another 
way to draw arrows, or to draw your circles and arrows in 1 step.

-- 
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.s...@imail.org
801.408.8111


 -Original Message-
 From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-
 project.org] On Behalf Of christophe dutang
 Sent: Friday, May 15, 2009 10:44 AM
 To: r-help@r-project.org
 Subject: [R] drawing arrows
 
 Hi,
 
 I would like to draw arrows in a classic 2D plot. Which package should
 I
 use? is there R base functions that do job?
 
 On google, I could not find any useful discussion about this topic,
 except a
 link to the function 'grid.arrows' of the grid package.
 
 My problem is I would like to draw arrows at the edge of circles drawn
 by
 the 'symbols' function. Maybe there is already a dedicated function for
 this?
 
 Any help is appreciated.
 
 Christophe
 
 
 
 --
 Christophe DUTANG
 Ph. D. student at ISFA
 
   [[alternative HTML version deleted]]
 
 __
 R-help@r-project.org 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.

__
R-help@r-project.org 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.


Re: [R] drawing arrows

2009-05-15 Thread Christophe Dutang
Thanks, I'll take a look.

Christophe

Le 15 mai 09 à 20:11, Greg Snow a écrit :

 Duncan mentioned the arrows function, which may do everything you  
 want.  But, also look at the my.symbols function in the  
 TeachingDemos package for another way to draw arrows, or to draw  
 your circles and arrows in 1 step.

 -- 
 Gregory (Greg) L. Snow Ph.D.
 Statistical Data Center
 Intermountain Healthcare
 greg.s...@imail.org
 801.408.8111


 -Original Message-
 From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-
 project.org] On Behalf Of christophe dutang
 Sent: Friday, May 15, 2009 10:44 AM
 To: r-help@r-project.org
 Subject: [R] drawing arrows

 Hi,

 I would like to draw arrows in a classic 2D plot. Which package  
 should
 I
 use? is there R base functions that do job?

 On google, I could not find any useful discussion about this topic,
 except a
 link to the function 'grid.arrows' of the grid package.

 My problem is I would like to draw arrows at the edge of circles  
 drawn
 by
 the 'symbols' function. Maybe there is already a dedicated function  
 for
 this?

 Any help is appreciated.

 Christophe



 --
 Christophe DUTANG
 Ph. D. student at ISFA

  [[alternative HTML version deleted]]

 __
 R-help@r-project.org 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.

Christophe Dutang
Ph. D. student at ISFA, Lyon, France
website: http://dutangc.free.fr




[[alternative HTML version deleted]]

__
R-help@r-project.org 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.


[R] drawing arrows with rgl

2008-01-29 Thread Kasper Peeters
Hi,

I am looking for a package which allows me to draw arrows (cylinders
with cones on them, basically) in 3d images produced with rgl. Is such
a thing available? 

I did notice the 'compositions' package, which contains
'arrow3D'. However, it relies on 'tensorA', which fails to install on
my machine with the error message copied below. If anyone can help me
fix this problem, that would do the trick too.

Best,
Kasper


trying URL 'http://www.sourcekeg.co.uk/cran/src/contrib/tensorA_0.31.tar.gz'
Content type 'application/x-tar' length 45248 bytes
opened URL
==
downloaded 44Kb

* Installing *source* package 'tensorA' ...
** libs
gcc -I/usr/lib/R/include -fPIC  -g -O2 -c tensora.c -o tensora.o
gcc -shared  -o tensorA.so tensora.o   -L/usr/lib/R/lib -lR
** R
** preparing package for lazy loading
Error in gettext(domain, unlist(args)) : invalid 'domain' value
Execution halted
ERROR: lazy loading failed for package 'tensorA'
** Removing '/usr/local/lib/R/site-library/tensorA'

The downloaded packages are in
/tmp/RtmpikOKjt/downloaded_packages
Warning message:
installation of package 'tensorA' had non-zero exit status in: install.packages
tensorA)

__
R-help@r-project.org 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.


Re: [R] drawing arrows with rgl

2008-01-29 Thread Duncan Murdoch
On 1/29/2008 6:23 PM, Kasper Peeters wrote:
 Hi,
 
 I am looking for a package which allows me to draw arrows (cylinders
 with cones on them, basically) in 3d images produced with rgl. Is such
 a thing available? 

The shapes3d demo in rgl draws cones.  You could use the same ideas to 
draw cylinders.

Once you have instructions to draw one prototypical arrow, you can use 
the scale3d, translate3d and rotate3d functions to reshape it and move it.

I've never found such arrows very visually pleasing, but if you do find 
a way to draw nice ones, please post the code here.

Duncan Murdoch

 
 I did notice the 'compositions' package, which contains
 'arrow3D'. However, it relies on 'tensorA', which fails to install on
 my machine with the error message copied below. If anyone can help me
 fix this problem, that would do the trick too.
 
 Best,
 Kasper
 
 
 trying URL 'http://www.sourcekeg.co.uk/cran/src/contrib/tensorA_0.31.tar.gz'
 Content type 'application/x-tar' length 45248 bytes
 opened URL
 ==
 downloaded 44Kb
 
 * Installing *source* package 'tensorA' ...
 ** libs
 gcc -I/usr/lib/R/include -fPIC  -g -O2 -c tensora.c -o tensora.o
 gcc -shared  -o tensorA.so tensora.o   -L/usr/lib/R/lib -lR
 ** R
 ** preparing package for lazy loading
 Error in gettext(domain, unlist(args)) : invalid 'domain' value
 Execution halted
 ERROR: lazy loading failed for package 'tensorA'
 ** Removing '/usr/local/lib/R/site-library/tensorA'
 
 The downloaded packages are in
 /tmp/RtmpikOKjt/downloaded_packages
 Warning message:
 installation of package 'tensorA' had non-zero exit status in: 
 install.packages
 tensorA)
 
 __
 R-help@r-project.org 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.

__
R-help@r-project.org 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.