Skip to content
Prev 174029 / 398502 Next

Way to rotate a histogram?

Can you reverse the x and y columns of the density object?

plot(density(c(-20,rep(0,98),20))$y, density(c(-20,rep(0,98),20))$x,
              xlim = c(0,1), ylim=c(-4,4), type='l', lwd=3, col='red')

--  
David Winsemius
On Mar 17, 2009, at 2:38 PM, Jason Rupert wrote:

            
David Winsemius, MD
Heritage Laboratories
West Hartford, CT