- Trending Categories
- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP

- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who

To remove the plot margin in base R between the axes and the points inside the plot, we can use xaxs and yaxs argument in plot function. Depending on the choices of the arguments xaxs and yaxs, the plot region in the respective direction is 4% larger than specified by these limits or exactly matches the "i" limits.

x<-rnorm(10) plot(x)

plot(x,xaxs="i",yaxs="i")

- Related Questions & Answers
- How to exclude extra margin between points and the axes for a plot created by using ggplot2 in R?
- How to create a base R plot without axes but keeping the frame of the plot?
- How to display axes ticks and labels inside the plot using ggplot2 in R?
- How to display X-axis labels inside the plot in base R?
- How to put the plot title inside the plot using ggplot2 in R?
- How to change the starting and ending points of axes labels using plot function in R?
- How to make the axes widths in a plot wider than default in base R?
- How to display base R plot axes titles in italics?
- How to check the difference between plot generation time in base R?
- How to remove Index in base R plot?
- How to change the axis color in base R plot?
- How to change the axes labels using plot function in R?
- Plot scatter points on 3d plot without axes and grids in Matplotlib
- How to change the color and size of the axes labels of a plot created by using plot function in R?
- How to remove scientific notation form base R plot?

Advertisements