Re: [R] RES: Multiple XY Lines Plot

From: Philipp Pagel <p.pagel_at_wzw.tum.de>
Date: Tue, 11 Nov 2008 21:27:49 +0100

> # prepare some example data
> x <- 1:25
> df <- data.frame(w1=x, w2=x+0.5, h1=x^2, h2=3*x+1.3)
>
> # use matplot to graph all data at once
> matplot(df[,c('w1','w2')], df[,c('h1','h2')], type='l', lty=c('solid', 'dotted'))

Oh - and matplot uses different line types anyway, so specifying lty is unnecessary, unless you don't like the default choice.

cu

        Philipp

-- 
Dr. Philipp Pagel
Lehrstuhl für Genomorientierte Bioinformatik
Technische Universität München
Wissenschaftszentrum Weihenstephan
85350 Freising, Germany
http://mips.gsf.de/staff/pagel

______________________________________________
R-help_at_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.
Received on Tue 11 Nov 2008 - 20:33:22 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 11 Nov 2008 - 21:30:24 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.

list of date sections of archive