R offers a remarkable variety of graphics. It has excellent graphics and plotting capabilities, which can mostly be found in 3 main sources: base graphics, the lattice package, the ggplot2 package.
Working with base graphics:
Step 1: To get an idea of different kinds of graphs that can be created, you can type demo(graphics) in the console.
Step 2: It leads you to a prompt called ‘Type <Return> to start :’ .
Step 3: It will ask you to ‘Hit <Return> to see next plot :’.
Step 4: It keeps on asking you to type return until it finds a ‘>’ prompt.
Simultaneously, it shows the following graphs every time you press return with a description in the console for the graph that is being created.
1. Here it shows a color wheel to have a relationship among the variables.
3. A Boxplot that graphically depicts group of numerical variables through their quartiles.
4. Below it shows a brownian or random motion of variables with respect to Time and Distance.
5. A line graph showing variations with time.
6. A histogram to see the change in variables among one or more variables.
7. A scatter plot showing change in variables in different ranges.
8. Scatter plot with the ranges showing variation in colors.
9. A topographic map categorized by a large scale of data.
10. Below it has used the par function to set or query graphical parameters. Here you can stop pressing return because you have encountered the ‘>’ prompt.
Viewing 3D graphs:
Step 1: Similarly, to have an idea about the 3D visualizations, type in demo(persp) in the console and press return(enter) when the prompt says ‘Type <Return> to start :’.
Step 2: It will ask you to ‘Hit <Return> to see next plot :’. Type return.
Stop pressing return when you encounter the ‘>’ prompt.