How to Reset the par Options Back to Default in R Programming (Example Code)

In this tutorial, I’ll illustrate how to reset par in the R programming language.

Creation of Example Data

par(mar = c(8, 5, 15, 8))        # Applying par function
plot(1:5)                        # Create example graph

r graph figure 1 how reset par options back default r programming

Example: Reset Options Specified with par() Using dev.off() Command

dev.off()                        # Use dev.off()
plot(1:5)                        # Recreating graph with default par options

r graph figure 2 how reset par options back default r programming

Leave a Reply

Your email address will not be published. Required fields are marked *

Fill out this field
Fill out this field
Please enter a valid email address.
You need to agree with the terms to proceed

Menu
Top