- 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 create a line chart in base R using plot function, we need to use type = "l" so that R understand the plot needs to have a line instead of points. If we want to increase the width of the line then lwd argument can be used. The value lwd = 0 is the default value for the width.

Consider the below vector and create the line chart −

x<-1:10 plot(x,type="l")

Create the line chart with larger width of the line −

plot(x,type="l",lwd=5)

Create the line chart with very wide line −

plot(x,type="l",lwd=10)

- Related Questions & Answers
- How to create a line chart using ggplot2 with larger width in R?
- How to create a horizontal line in ggplot2 graph with larger width in R?
- How to create quantile regression plot with larger width of lines using ggplot2 in R?
- How to create a line chart using ggplot2 with a vertical line in R?
- How to create varying width bar chart using barplot function in R?
- How to create a plot in R with gridlines using plot function?
- How to create grouped line chart using ggplotly in R?
- How to create a line chart using JavaFX?
- How to create a line chart using Matplotlib?
- How to create line chart using ggplot2 in R with 3-sigma limits?
- How to create a plot in R with a different plot window size using plot function?
- How to create a line chart with mean and standard deviation using ggplot2 in R?
- How to create a plot in base R with tick marks of larger size?
- How to create multiple lines chart with unique line types in R?
- How to create a plot with dashed regression line in base R?

Advertisements