Displaying 20 results from an estimated 20000 matches similar to: "Conditional error bars"
2007 Jul 25
3
Constructing bar charts with standard error bars
I am new to R.
I want to graph group data using a "Traditional Bar Chart with Standard
Error Bar", like the kind shown here:
http://samiam.colorado.edu/~mcclella/ftep/twoGroups/twoGroupGraphs.html
Is there a simple way to do this?
So far, I have only figured out how to plot the bars using barplot.
testdata <- scan(, list(group=0,xbar=0,se=0))
400 0.36038 0.02154
200 0.35927
2001 Nov 08
2
Error Bars
I'm trying to draw some error bars on a bar chart. I'm using code like
this:
thing <- c(3,3,3)
se <- c(1,1,1)
names(thing) <- c("A", "B", "C")
barplot(thing, ylim=c(0,4))
arrows(c(1:3), thing-se, c(1:3), thing+se, code=3, angle=90,length=0.1)
Using c(1:3) has 2 problems:
1. Obviously it is untidy, but using names(thing) doesn't work, and I
1999 Aug 26
1
error bars on barplots
Hello again
I'm trying to put error bars onto a barplot. I've tried something that
Bill Simpson suggested a while ago, ie:
x<-c(1,2,3,4,5)
y<-c(1.1, 2.3, 3.0, 3.9, 5.1)
ucl<-c(1.3, 2.4, 3.5, 4.1, 5.3)
lcl<-c(.9, 1.8, 2.7, 3.8, 5.0)
plot(x,y, ylim=range(c(lcl,ucl)))
arrows(x,ucl,x,lcl,length=.05,angle=90,code=3)
#or
segments(x,ucl,x,lcl)
but I can't get it to work on a
2007 Oct 22
4
Bar plot with error bars
Apologies if this has been asked before. I am having trouble
understanding the R mailing list never mind R!
I am relatively new to R having migrated from Minitab and SPSS. I
have managed to do some more complicated statistics such as
hierarchical partitioning of variance on an 80,000 record dataset but
have to admit that drawing a simple bar plot I could do by hand is
proving extremely
2010 Dec 18
1
Can I make my colnames bold?
Hello forum! As the subject indicates, I am trying to make a barplot and
would like my column names to be in bold. Is this possible in R without
having to make my column names in mtext? Any help would be much
appreciated. The code I am using is as follows.
par(mar=c(3,8,2,2))
par(adj=.5)
par(font=2)
par(oma=c(3,3,3,3))
par(xpd=TRUE)
Blot<-matrix(c(25.2995, 0.7625, 25.6135, 36.5770,
2009 Dec 03
5
Bar Plots: Error Bars
Hey Everyone,
I'm pretty new at R and wanted to try and make some graphs with dummy data
before using it to analyze my own. I successfully made a bar graph and error
bars, but I can't figure out how to align them properly (currently they are
not centered on the bars and some of them aren't even close). Here's the
code that I'm using:
> marks <- sample(4:10, size=50,
2011 Jun 03
2
Y error bars, dates on the X-axis
Dear forum,
Does anyone know any functions for plotting vertical error bars, if the
x-axis variable is a date?
I can produce a pretty plot with dates on the x-axis, if I don't want to
include error bars. I can also produce a nice plot with error bars, if I
just use Julian days for the x-axis, but I'd much rather have the actual
dates.
I have tried writing my own function, plotCI
2005 Jun 30
1
Graphically centering confidence interval in barplot
Hello,
I have got a simple "cosmetic" question.
I have created a bar plot with confidence intervals using:
barplot(mean, ylim = c(0,0.2), las = 3, space = 0)
arrows(1:17 ,X95p_low, 1:17, X95p_high, length = 0.07, angle = 90, code
= 3, lty = 1)
Unfortunately, the confidence bars align with the right side of the bars
and I would like to shift these to the middle of the bars.
Is
2006 Nov 24
1
barplot help needed
hello,
I would like to create the following barplot:
I have 4 different data sets (same length + stddev for each data point)
data1
sd1
data2
sd2
data3
sd3
data4
sd4
now, I'd like to plot in the following way:
data1[1],data2[1],data3[1],data4[1] with it's sd-values side-by-side at
one x-axis label (named "position 1") and each bar in different colors.
2010 Jun 11
2
Misplacement of Greek letter
Hello.
I am trying to get my axis label to read as follows
(The symbol) Delta AUC blah blah...
then below it...(some other text)
The problem is the Delta symbol shows up beside the "(some other text)"
rather than the "AUC". Does any one know how I can get the Delta to remain
beside AUC?
Here is the actual command should you care to look at it.
par(mar=c(8,8,4,4))
2006 Mar 27
2
A plotting question - how to get error bars?
Dear R list,
Can anyone help with a plotting question? I'm trying to display some data
on a plot and I've almost got the format I need (see code below), but 2
things I can't get:
1. How to get "Jan","Feb","Mar" on the x=axis instead of 1:3?
2. How to get "T"s on the end of my error bars like you have in standard
scientific plots?
Any comments
2006 Jun 06
2
error bars in lattice xyplot *with groups*
Hi all,
I'm trying to plot error bars in a lattice plot generated with xyplot. Deepayan
Sarkar has provided a very useful solution for simple circumstances
(https://stat.ethz.ch/pipermail/r-help/2005-October/081571.html), yet I am
having trouble getting it to work when the "groups" setting is enabled in
xyplot (i.e. multiple lines). To illustrate this, consider the singer data
2008 Jun 03
0
problems on plotting adjacent bars with barplot. Help request, please
hi ladyes and gentlemans of the R comunity.
i have the following graphical issue:
# say y is a matrix or a dataframe with
dim(51,nrow=17),hence 3 columns;
l<-51
# now the 3 colums represents 3 different aspects of
my continuous variable (3 factors),plotted against a
categorical one;
n<-levels(factor(x))
# i want to plot those 3 factors adjacently using the
barplot(), and possibly show
2002 Jun 17
3
Error bars.
There was an inquiry on this list recently about plotting some simple
error bars on a graph. Now Splus has a function (error.bar ---
originally written by Sue Clancy of DMS, CSIRO, I believe) to do this
job virtually at the touch of a key. (Well a few keys. :-) ) The
error.bar function is written completely in raw S --- no calls to
``.Internal'' or anything like that. So it would be
2008 Feb 15
3
lineplot.CI problem
Hi List,
I have a problem plotting data using the lineplot.CI command in the sciplot package.
I want to plot the data of 2 experimental cases using different lines (traces). Time is on the X-axis. The tricky thing is that the data collection in the second case started later than for the first case. This is to say: the first n data points for the second case are missing.
So far so good. However,
2006 Jul 16
1
break axis using plotrix
Dear all,
I am trying to plot some data with differing range in y-values with
type="b", adding error bars and break the y-axis into two parts, one
lower part from 12 to 20, and one upper part from 34 to 40.
I have tried to follow the basic ideas from the script provided here by
Jim Lemon:
http://finzi.psych.upenn.edu/R/Rhelp02a/archive/56487.html
My attempt looks like this:
2006 Jul 07
4
How to change the type of segments ends?
Hi,
I am trying to plot odds ratios and the corresponding confidence
intervals in horizontal segments. It would be ideal if the confidence
interval segment can be drawn with little vertical bars at both ends. I
have tried very hard to change the type of ends by using 'lend'
arguments, but cannot make it. I even tried 'arrows()', but still
failed. Following is the code I use:
2010 Sep 09
3
Alignment of lines within barplot bars
Dear all,
I have a barplot upon which I hope to superimpose horizontal lines extending across the width of each bar. I am able to partly achieve this through the following set of commands:
positions <- barplot(bar_values, col="grey")
par(new=TRUE)
plot(positions, horiz_values, col="red", pch="_", ylim=c(min(bar_values), max(bar_values)))
...however this results
2017 Jun 19
1
arrows: no vectors for "code" and "angle" parameters
I was teaching new R users to make some fun graphs. I had some arrows examples
worked up we came across a problem. The arrows function ignores 2nd
and following elements of vectors given as code an angle.
Would you please consider 1) allowing vectors for code and angle, or
2) returning an error or warning when user mistakenly supplies a
vector for those parameters? When code like this is
2002 Oct 06
6
error bars in line plots
Hi!
Could you tell me how I can draw a graph with error bars?
Sorry, I don't use R that often and I couldn't find it easily in the
documentation.
TIA
--
myriam
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info",