Displaying 20 results from an estimated 188 matches for "ymin".
Did you mean:
min
2010 Apr 04
4
ggplot2 geom_rect(): What am I missing here
...nt the duration of the cycle (in months). In other words, all
rectangles have coordinates (start, duration) and (end, duration).
rr
I've spent hours trying to figure out the documentation and pouring over
Google and RSeek searches and am at an impasse. The documentation refers
to xmin, xmax, ymin, and ymax but doesn't say anything about them. The
only example gives them both as vectors, so I assume they refer to a
sequence of coordinates in which each rectangle's vertices is given by
(xmin[i],ymin[i]), (xmin[i],ymax[i]), (xmax[i],ymax[i]), and
(xmax[i],ymin[i]). But when I try t...
2013 May 18
3
bar plot with non-zero starting level
Hi,
I want to plot grouped bars to compare 95% confidence interval estimates
from two models. Each bar represents a 95% confidence interval estimate
of a coefficient from one of the two models. Each group represents
confidence interval estimates of the same coefficient from the two models.
I think such a bar plot will nicely present whether 95% confidence
interval estimates of the same
2008 Jul 29
4
Graphics function question
Hello
I have created a graph using the following commands:
<<<
startBReP3O1T <- diffs$BReP3O1T - diffs$diff_BReP3O1T
endBReP3O1T <- diffs$BReP3O1T
x <- seq(47,89, length = 10)
ymin <- min(min(startBReP3O1T), min(endBReP3O1T))
ymax <- max(max(startBReP3O1T), max(endBReP3O1T))
y <- seq(ymin, ymax, length = 10)
plot(x,y, type = 'n', xlab = 'Age', ylab = 'BReP3O1T', main = 'Age, decline and BReP3O1T')
segments(x0 = startage, x1 = endage, y...
2003 Sep 17
1
plot.hclust: dendrogram too large for window (PR#4197)
...t fit
within the window.
I propose the fix listed below.
src/main/
--- plot.c Wed Sep 17 01:03:39 2003
+++ plot.c.new Wed Sep 17 01:21:59 2003
@@ -3314,7 +3314,7 @@
SEXP do_dendwindow(SEXP call, SEXP op, SEXP args, SEXP env)
{
int i, imax, n;
- double pin, *ll, tmp, yval, *y, ymin, ymax, yrange;
+ double pin, *ll, tmp, yval, *y, ymin, ymax, yrange, m;
SEXP originalArgs, merge, height, llabels, str;
char *vmax;
DevDesc *dd;
@@ -3357,8 +3357,14 @@
ll = (double*)R_alloc(n, sizeof(double));
dnd_lptr = &(INTEGER(merge)[0]);
dnd_rptr = &(I...
2012 Feb 03
1
incomplete final line found on <name of my sourced function file>
...t;#473C8B","#8B4500", "#FF7F00","#9370DB",
"#800000","#104E8B","#228B22")[20:1]
myagg<-aggregate(indata[invars],by=indata[datesvar],FUN=myfunction)
yrange=range(pretty(as.matrix(myagg[2:length(myagg)])))
if(fixedy==0){
ymin<-yrange[1]
ymax<-yrange[2]} else {
ymin<-0
ymax<-yrange[2]}
ydistance<-ymax-ymin
if(ydistance>0.1 & ydistance<=1){mystep<-0.1} else {
if(ydistance>1 & ydistance<=10){mystep<-1/2} else {
if(ydistance>10 & ydistance<=100) {mystep...
2008 Jul 30
1
read XML
...t;layout>
<name>Layout 2</name>
<pagesByX>1</pagesByX>
<pagesByY>1</pagesByY>
- <elements>
<legend refParent="r3" xmax="0.54156171284634758"
xmin="0.020151133501259435" ymax="0.31480598161051165"
ymin="0.042461931948864044" />
<component background="auto" border="none" borderDegMinSec="false"
borderEachPage="true" borderFont="Tahoma, 8" borderFore="#000000"
borderMargin="12" borderNoOverlaps="true"...
2009 Aug 06
2
Ylim
...;white",res=50)
par(mar=c(5, 5, 3, 2),lwd=5)
par(cex.main=1.6,cex.lab=1.6,cex.axis=1.6)
par(mfrow = c(3,4))
ifn <- "T.dat"
trait <- read.table(ifn)
i <- 1
j <- 1
for(k in 1:12)
{
dat <- data[i:(i+2), ]
colnames(dat)<-c("SM","E","NP)
Ymin <- if( min(dat$SM) < 0.0 ) (dat$SM - dat$E) else 0.0
Ymax <- if( max(dat$SM) > 0.0 ) (dat$SM + dat$E) else 0.0
Graph<-barplot(dat$SM, names.arg=dat$NP, main = trait[j:j,], xlab =
data[i:i,1:1], ylim = c(Ymin,Ymax) )
segments(Graph, dat$SM + dat$E, Graph, dat$SM - dat$E)
i <- i +...
2011 Jul 01
1
highlighting clusters in a heatmap
I would like to draw horizontal or vertical lines on a heatmap to
highlight the clusters at some specified cut depth of the dendrogram.
As a hacked example, the following code would work if I could set the
coordinates of the top and bottom of the false color image correctly
(ymin and ymax), but the correct values seem to depend on the output
device and its size. I realize that heatmaps use a 2x2 layout which
makes the coordinate system non-obvious, but the result seems very
difficult to customize. I would appreciate any suggestions for manual
or pre-made solutions.
Examp...
2010 Nov 04
5
ggplot output
Dear All,
I have this script:
dat <- data.frame(Month = hstat$Date,C_avg = hstat$C.avg,C_stdev =
hstat$C.stdev)
ggplot(data = dat, aes(x = Month, y = C_avg, ymin = C_avg - C_stdev, ymax =
C_avg + C_stdev)) +
geom_point() +
geom_line() +
geom_errorbar()
dat <- data.frame(Month = hstat$Date,K_avg = hstat$K.avg,K_stdev =
hstat$K.stdev)
ggplot(data = dat, aes(x = Month, y = K_avg, ymin = K_avg - K_stdev, ymax =
K_avg + K_stdev)) +
geom_point() +...
2011 Jan 24
1
ggplot2 - ribbon
Dear List,
I am having trouble setting the transparency of a ribbon in ggplot2 and was wondering if anybody had any suggestions
so far i have a plot exactly as i want it and i want to add a ribbon connecting the ymax and ymin, whci i do with the following command
m10 + stat_summary(geom="ribbon", fun.ymin="min", fun.ymax="max")
However the ribbon is a dark grey and i want to make it much lighter or change the colour. I was wondering if anybody had any ideas?
I have kept the code used so...
2012 Jul 26
2
Error Bars ggplot2
...,3.2,2.1,.2,3.8,6.4,7.5,1.7,3.4,4.1,2.2,5)
#Turn spd into a factor
spd.f<-factor(spd)
#Place data into a data frame
data<-data.frame(cbind(spd.f,r))
#Load ggplot2
library(ggplot2)
#Create plot
pd<-position_dodge(.2)
myplot<-ggplot(data,aes(x=spd,y=r,colour=spd))+
geom_errorbar(aes(ymin=3,ymax=5),width=.1)+
geom_point()+
geom_errorbar(aes(ymin=1,ymax=6),width=.1,colour="black",position=pd)
#Display plot
myplot
I have attached a plot that my sample code produces. As you can see the
error bars are stacked. How can I get them to plot side by side?
Thanks
AG
2009 Sep 15
2
How to calculate min of a dataset that contains empty column
Hi all,
I have got a dataset like the following:
a b c
1 5
2
3 7
I am taking the minimum of each column and use it as the minimum of the
y-axis of my graphs. My scripts (simplified version) are like the following:
f<-array
f[1]=a
f[2]=b
f[3]=c
for i in 1:3
name=f[i]
ymin<-min(dataset$f[i])
plot(x,y,ylim=c(ymin,100))
The script stops at b, because the min function returns inf value. What can
I do to overcome it?
Many thanks,
Chris
--
View this message in context: http://www.nabble.com/How-to-calculate-min-of-a-dataset-that-contains-empty-column-tp25463449p2546...
2001 Feb 28
1
Spider diagrams
Hi, I am trying to create what are called "spider diagrams" in the geochemical
literature using R. A spider diagram is basically a plot of the atomic number
versus the concentration on a log scale. Lines are drawn from each atomic
number for each sample.
Right now, my data frame looks like:
SAMPLE SITE V3 LA.NASC LAATNUM CE.NASC CEATMNUM
1 1A:001
2013 Feb 03
1
ggplot2 plotting errorbars.
Hi,
i'm using this lines of code:
dodge <-position_dodge(width=0.9)
ggplot(dfm,aes(x = X,y = value)) +
geom_bar(aes(fill = variable), position=dodge, stat="identity") +
geom_errorbar(aes(ymin=value-er, ymax=value+er),width=0.25,
position=dodge,stat="identity")
to plot this data frame
X variable value er
1 A X4 58.74 9.44
2 B X4 52.41 10.01
3 C X4 95.52 4.88
4 A X1 75.51 8.54
5 B X1 0.73 23.20
6 C X1 96.66 1.18
7 A...
2006 Jun 25
0
Fighting with GDD & lwd
...ompiling and installing the GDD package under my FreeBSD 6.1
box after eliminating
ifdef DEBUG
? ?PKG_CFLAGS+=-DJGD_DEBUG
endif
in Makevars.in
Now, with the following code
..............................................
grafico1<- function() {
plot(1:length(tabella[,1]),tabella[,2],ylim=c(Ymin,Ymax),type="h",
lwd=6,col="red",main=paste("TEMPERATURE MEDIE GIORNALIERE\nMESE DI",
toupper(format(ierid,"%B")),sep=" "),
col.main="dark blue", xlab="Giorni del mese",ylab="?C",
col.lab="blue",axes...
2010 Sep 16
1
plotting time series using ggplots
...ts around the mean for each year. I
cannot figure out how to do this except for this really clunky way:
rwl$year<-as.numeric(rownames(rwl))
h<-ggplot(rwl, aes(x=year))
h+ geom_line(aes(y=V1)) #plots one of the timeseries
ymax=as.data.frame( t(apply(rwl[1:8], 1, summary,na.rm=TRUE )) )[,4]
ymin=as.data.frame( t(apply(rwl[1:8], 1, summary,na.rm=TRUE )) )[,2]
h + geom_ribbon(aes(ymin=ymin, ymax=ymax))
+geom_line(aes(y=rowMeans(rwl[1:8])))
2) I'd like to be able to plot all of the timeseries together, or plot
them grouped by another variable (for example site), but I can't
figu...
2011 Jan 11
0
modified FAST Script from package SensoMineR for the R community - Reg
...ly(group.quali.sup,
function(k) seq(nbre.grpe * (k - 1) + 1, length =
nbre.grpe))),
1])
xlim <- c(xmin, xmax) * 1.1
}
else {
xmin = xlim[1]
xmax = xlim[2]
}
if (is.null(ylim)) {
ymin <- ymax <- 0
if (is.na(test.invisible[1]))
ymin <- min(ymin, coord.ind[, 2])
if (is.na(test.invisible[1]))
ymax <- max(ymax, coord.ind[, 2])
if (!is.null(res.mfa$ind.sup) & is.na(test.invisible[2]))...
2013 May 14
1
Tamaño plots y calidad en grafico ggplot
...;1","a","Nivel 2","Nivel 3","c","d")
niveles=data.frame(inicio,fin,Niveles)
Jurisdiction=rownames(mtcars)
for (i in 1:length(Jurisdiction))
if(Jurisdiction[i]=="Fiat 128"){k=i}
h <- ggplot(tabla, aes(x=factor(Jurisdiction), y=Mean, ymin=245, ymax=305))
h +
scale_fill_manual(values = c("#A0551E", "#FA964B","#E1EBFF", "#B4CDFF",
"#055014","#A0551E"))+
geom_hline(yintercept = seq(245, 305, 10), linetype=2, colour="#E1EBFF")+
geom_vline(xintercept = seq(1, 33, 2.5)...
2006 Jun 28
2
read file with readBin (the file was saved with a C-routine)
...t YSamples; /* No of samples on 2. axis of recon image */
float DeltaX; /* Sampling distance 1. axis of recon image */
float DeltaY; /* Sampling distance 2. axis of recon image */
float Xmin; /* 1. sample position 1.axis of recon image */
float Ymin; /* 1. sample position 2.axis of recon image */
} itINItype;
I thought the following use of "readBin" sould it do, but it doesn't
KernelFileSave <- readBin( con, integer(), n=1, size=4 )
KernelFileName <- readBin( con, character(), n=1 )
StartFileName <- rea...
2011 Nov 16
1
geom_bar with missing data in package ggplot
...ue))
gp<- gp + geom_line()
gp <-gp + facet_grid(var2 ~ variable)
gp
this works, but trying to get a bar chart version
gp <- ggplot(g, aes(Date, value))
gp<- gp + geom_bar(stat="identity")
gp <-gp + facet_grid(var2 ~ variable)
gp
gives the error
Error in if (!is.null(data$ymin) && !all(data$ymin == 0))
warning("Stacking not well defined when ymin != 0", :
missing value where TRUE/FALSE needed
Is there something I can do to have a gap for missing data, as happens
with the line version?
More generally, I may also have missing data between present dat...