Thank you for reply.
If I'm not wrong, legend(...) will works for discrete elements.  I'm not sure hot to use it for a colorbar legend sur as the one in the example bellow.
Phil
> Date: Mon, 2 Dec 2013 11:49:19 -0800
> From: carl@witthoft.com
> To: r-help@r-project.org
> Subject: Re: [R] legend position
> 
> See ?legend .   you can add a legend directly to an existing plot.  An
> example:
> 
> legend('topright',c('hot','cold'),lty=1,col=c('red','green'),bg='white')
> 
> Now if you're trying to place the legend outside the plot area (i.e. in some
> other part of the window),
> you'll need to invoke par(xpd=TRUE) . See the help at ?par .
> 
> 
> Filoche wrote
> > Hi all. 
> > I'm ploting a raster and I can't find the proper way to move the legend.
> > For example,
> > r = raster(system.file("external/test.grd", package="raster"))plot(r)
> > How can I put the legend at the desired position?
> > Thank in advance,Phil 		 	   		  
> > 	[[alternative HTML version deleted]]
> > 
> > ______________________________________________
> 
> > R-help@
> 
> >  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.
> 
> 
> 
> 
> 
> --
> View this message in context: http://r.789695.n4.nabble.com/legend-position-tp4681489p4681492.html
> Sent from the R help mailing list archive at Nabble.com.
> 
> ______________________________________________
> 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.
 		 	   		  
	[[alternative HTML version deleted]]

