- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
How to create a histogram without bins in base R?
We can set type argument to s in plot function to create a histogram without bins but first we need to create the histogram and store it in an object. For example, if we have a vector say x then the histogram of x can be stored in an object called p then we can use the command plot(c(p$counts,0),type="s") to create the histogram without bins as shown in the below example.
Example
> x<-rnorm(100) > p<-hist(x)
Output
Example
> plot(c(p$counts,0),type="s")
Output
- Related Articles
- How to create a horizontal line in a histogram in base R?
- How to create a boxplot without frame in base R?
- How to create a plot in base R without margins?
- How to create a histogram with dots instead of bars in base R?
- How to highlight a bar in base R histogram?
- How to create boxplot in base R without axes labels?
- How to have logarithmic bins in a Python histogram?
- How to create bins for a continuous vector in R?
- Create histogram with horizontal boxplot on top in base R.
- How to create a boxplot in base R without any axes except Y?
- How to create horizontal histogram in R?
- How to create a histogram using weights in R?
- How to create a histogram with main title in the outer margin of plot window in base R?
- How to create a transparent histogram using ggplot2 in R?
- How to create a step histogram using ggplot2 in R?

Advertisements