There are several ways to generate a picture. We can summarize them into the following four methods:
- Method #1: Using the Snipping Tool
- Method #2: Saving the picture by clicking it
- Method #3: Using Ctrl + Shift + PrintScrn and the Paint software
- Method #4: Using our programs
The easiest way to save our picture is to use the Snipping Tool. After a picture is generated, launch the Snipping Tool and choose an appropriate area to save. The following example shows the simplest output to a PDF file in R. Let's use the previous example code of drawing a cosine function from -2π to 2π, shown here:
pdf("c:/temp/myGraph.pdf") plot(cos,-2*pi,2*pi) dev.off()