Learn R Programming

DescTools (version 0.99.19)

Mar: Set Plot Margins

Description

Plot margins are normally set by par("mar"). However one is forced to define all margins, even if just one should be altered. This convenience function allows to set one single margin (or several) while leaving the others unchanged.

Usage

Mar(bottom = NULL, left = NULL, top = NULL, right = NULL, outer = FALSE)

Arguments

bottom
the bottom margin, if set to NULL the current value will be maintained.

left
the left margin, if set to NULL the current value will be maintained.

top
the top margin, if set to NULL the current value will be maintained.

right
the right margin, if set to NULL the current value will be maintained.

outer
logical, defining if inner margins (par("mar")) or the outer margins (par("oma")) should be set. Default is FALSE, meaning that the inner margins will be concerned.

See Also

par

Examples

Run this code
# largen the left margin only
Mar(left=10.1)   # or as alternative: Mar(, 10.1)
barplot(1:7, names=levels(d.pizza$driver))

Run the code above in your browser using DataLab