[R] Legend: Custom distance between lines and text

Sebastian Schubert schubert.seb at googlemail.com
Sat Jun 9 17:33:16 CEST 2012


On 09/06/12 13:20, peter dalgaard wrote:
>> I guess I overlook the corresponding part in the manual but how can I
>> modify the distance between the text and the line in a legend?
>>
>> Thank you for any hints!
> 
> You mean like this?
> 
> plot(0)
> legend(1, .5, legend=c("foo","bar"), lty=1:2, pch=NA)
> legend(1, .25, legend=c("foo","bar"), lty=1:2, pch=NA, x.intersp=2)

Thanks a lot. I think I even tried x.intersp before, worked fine now.

Sebastian

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <https://stat.ethz.ch/pipermail/r-help/attachments/20120609/d5ec8a81/attachment.bin>


More information about the R-help mailing list