R Graphics

819 views
766 views

Published on

R Graphics

Published in: Technology, Art & Photos
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
819
On SlideShare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

R Graphics

  1. 1. Graphics<br />The Dataminingtools.net Team<br />
  2. 2. R Graphics<br />Image source: www.stat.auckland.ac.nz/~paul/RGraphics/chapter1.pdf<br />
  3. 3. R Graphics<br />Image source: www.stat.auckland.ac.nz/~paul/RGraphics/chapter1.pdf<br />
  4. 4. R Graphics<br />Image source: www.stat.auckland.ac.nz/~paul/RGraphics/chapter1.pdf<br />
  5. 5. R Graphics<br />Image source: www.stat.auckland.ac.nz/~paul/RGraphics/chapter1.pdf<br />
  6. 6. R Graphics<br />Image source: www.stat.auckland.ac.nz/~paul/RGraphics/chapter1.pdf<br />
  7. 7. Types of functions<br />Functions in the graphics systems and graphics packages can be broken down into three main types: <br />high-level functions that produce complete plots; <br />Low-level functions that add further output to an existing plot; and <br />functions for working interactively with graphical output.<br />Image source: www.stat.auckland.ac.nz/~paul/RGraphics/chapter1.pdf<br />
  8. 8. Organization of R graphics<br /><ul><li>The R graphics system can be broken into four distinct levels:</li></ul>graphics packages; <br />graphics systems; <br />a graphics engine, including standard graphics devices; and<br />graphics device packages<br />Image source: www.stat.auckland.ac.nz/~paul/RGraphics/chapter1.pdf<br />
  9. 9. Plot<br />Plot is a generic function for plotting of R objects.<br />Usage:<br /><ul><li>plot(x, y, ...)</li></li></ul><li>Plot<br />&gt; plot(pressure, type=&quot;l&quot;)<br />
  10. 10. Plot<br />&gt; plot(pressure, type=&quot;S&quot;)<br />
  11. 11. Plot<br />Arguments to be passed to methods, such as graphical parameters (see par). Many methods will accept the following arguments:<br />typewhattype of plot should be drawn. <br />main: an overall title for the plot<br />sub: a sub title for the plot<br />xlab: a title for the x axis: <br />ylab: a title for the y axis:<br />asp: the y/x aspect ratio, <br />
  12. 12. Plot<br />Possible types are:<br />&quot;p&quot; for points,<br />&quot;l&quot; for lines,<br />&quot;b&quot; for both,<br />&quot;c&quot; for the lines part alone of &quot;b&quot;,<br />&quot;o&quot; for both ‘overplotted’,<br />&quot;h&quot; for ‘histogram’ like (or ‘high-density’) vertical lines,<br />&quot;s&quot; for stair steps,<br />&quot;S&quot; for other steps,<br />&quot;n&quot; for no plotting.<br />
  13. 13. Plot<br />&gt; plot(pressure, type=&quot;o&quot;, main=&quot;Pressure Vs Temperature plot&quot;)<br />

×