Hello, With the new version 2.2.0, I get strange plots when using the histogram-like option in plot(). For example, a plot of binomial probabilities:> plot(0:10,dbinom(0:10,10,.1), type = "h", lwd = 30)gives me weird fat cirular bars, with mass out at values with low probability. What is the issue here? This never happened with earlier versions. R on Windows XP SP 2 Intel processor Jason
?par "lend" Before plotting: par(lend='square') -- Bert Gunter Genentech Non-Clinical Statistics South San Francisco, CA "The business of the statistician is to catalyze the scientific learning process." - George E. P. Box> -----Original Message----- > From: r-help-bounces at stat.math.ethz.ch > [mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Owen, Jason > Sent: Wednesday, November 30, 2005 9:15 AM > To: r-help at stat.math.ethz.ch > Subject: [R] strange plots with type = "h" option > > Hello, > > With the new version 2.2.0, I get strange plots when using the > histogram-like option in plot(). For example, a plot of binomial > probabilities: > > > plot(0:10,dbinom(0:10,10,.1), type = "h", lwd = 30) > > gives me weird fat cirular bars, with mass out at values with low > probability. What is the issue here? This never happened > with earlier > versions. > > R on Windows XP SP 2 > Intel processor > > Jason > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide! > http://www.R-project.org/posting-guide.html >
Look at ?par specifically at the 'lend' argument. You probably want to do: par(lend=1) Before doing your plot. -- Gregory L. Snow Ph.D. Statistical Data Center, IHC greg.snow at ihc.com (801) 408-8111> -----Original Message----- > From: r-help-bounces at stat.math.ethz.ch > [mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Owen, Jason > Sent: Wednesday, November 30, 2005 10:15 AM > To: r-help at stat.math.ethz.ch > Subject: [R] strange plots with type = "h" option > > Hello, > > With the new version 2.2.0, I get strange plots when using > the histogram-like option in plot(). For example, a plot of binomial > probabilities: > > > plot(0:10,dbinom(0:10,10,.1), type = "h", lwd = 30) > > gives me weird fat cirular bars, with mass out at values with > low probability. What is the issue here? This never > happened with earlier versions. > > R on Windows XP SP 2 > Intel processor > > Jason > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide! > http://www.R-project.org/posting-guide.html >
Thanks a lot! I wonder why that isn't the default....> -----Original Message----- > From: Berton Gunter [mailto:gunter.berton at gene.com] > Sent: Wednesday, November 30, 2005 1:14 PM > To: Owen, Jason; r-help at stat.math.ethz.ch > Subject: RE: [R] strange plots with type = "h" option > > ?par "lend" > > Before plotting: > > par(lend='square') > > > -- Bert Gunter > Genentech Non-Clinical Statistics > South San Francisco, CA > > "The business of the statistician is to catalyze the > scientific learning > process." - George E. P. Box > > > > > -----Original Message----- > > From: r-help-bounces at stat.math.ethz.ch > > [mailto:r-help-bounces at stat.math.ethz.ch] On Behalf Of Owen, Jason > > Sent: Wednesday, November 30, 2005 9:15 AM > > To: r-help at stat.math.ethz.ch > > Subject: [R] strange plots with type = "h" option > > > > Hello, > > > > With the new version 2.2.0, I get strange plots when using the > > histogram-like option in plot(). For example, a plot of binomial > > probabilities: > > > > > plot(0:10,dbinom(0:10,10,.1), type = "h", lwd = 30) > > > > gives me weird fat cirular bars, with mass out at values with low > > probability. What is the issue here? This never happened > > with earlier > > versions. > > > > R on Windows XP SP 2 > > Intel processor > > > > Jason > > > > ______________________________________________ > > R-help at stat.math.ethz.ch mailing list > > https://stat.ethz.ch/mailman/listinfo/r-help > > PLEASE do read the posting guide! > > http://www.R-project.org/posting-guide.html > > > >