CHAPTER 6 GRAPHICAL PARAMETERS

6.1 Defining Colours

6.2 Defining Symbols (Points)

6.3 Defining Line Types

6.4 Saving Plots

1. Create an empty file in your working directory with your specified parameters
2. Create your plot
3. Save your plot by turning device off
Example:
png("Figure1.png", width = 100, height = 100, units = 'mm', res = 300)
with(PlantGrowth,hist(weight,
      xlim= c(3,7),                       # set the x-axis range
      ylim= c(0,10),                      # set the y-axis range
      col= "lightgray",                   # fill the columns
      border= "black",                    # column border
      main= "Histogram of Plant Weights", # figure title
      xlab= "Dried weight (g)",           # x-axis label
      ylab= "Frequency"))                 # y-axis label
dev.off()
## png 
##   2