0

A have 2 datasets

Summer 1 :

Time  Temerature
1          12,5
500        13,5
1000       15    
1500       16
2000        19
2500       20
3000       21

summer 2

Time  Temperature
1          12,5
500        13,5
1000       15    
1500       16
2000        19
2500       20
3000       21
3500       23
4000       34

I want to plot the 2 temperature curves (summer 1 and summer 2) according to the time in R. The problem here concerns the axis for the 2 datasets which are not the same : summer 1 (from 1 to 3000) and summer 2 (from 1 to 4000). Can you help me please?

IRTFM
  • 240,863
  • 19
  • 328
  • 451
Mabrouk Hmed
  • 9
  • 1
  • 2
  • 1
    Use search to find old plot posts. Several possibilities will show up. For example: http://stackoverflow.com/questions/5479822/plotting-4-curves-in-a-single-plot-with-3-y-axes-in-r/5480489#5480489 – bill_080 Jun 09 '13 at 17:08
  • My search with: `[r] plot lines` found over 3,000 hits and the first one seemed an exact answer to this question: http://stackoverflow.com/questions/2564258/plot-2-graphs-in-same-plot-in-r/2564276#2564276 – IRTFM Jun 09 '13 at 17:44
  • 2
    To accommodate different ranges of the data you want to plot, you can provide values to the `xlim` and `ylim` arguments of `plot`. See `?plot.default` for an explanation of these arguments. – BenBarnes Jun 09 '13 at 18:04

0 Answers0