similar to: lattice plot query

Displaying 20 results from an estimated 10000 matches similar to: "lattice plot query"

2009 Oct 09
1
Placing text in a ggplot
I am attempting to graph 12 months of temperatures, delineate the months with a vline and place the names of the months at the top of the graph. So far I have gotten everything to work except the names, despite getting a similar graph to work yesterday the day before yesterday with Baptise A's help. Can anyone suggest what I am doing wrong. Data set is below code. Thanks. Code
2009 May 28
2
ggplot2 legend
Hi: I need some help with the legend. I got 14 samples(Muestreo) and I am trying to plot a smooth line for each sample. I am able to accomplish that but the problem is that the legend only displays every other sample. How can I force the legend to show all of my Muestreos? Thanks in advance. fish_ByMuestreo <- structure(list(data = structure(list(SampleDate = structure(c(3L, 3L, 3L, 3L,
2017 Jul 22
1
3-day moving average for block maxima
Dear r-users, I would like to construct 3-day moving average for block maxima series. I tried this: bmthree <- lapply(split(dt, dt$Year), function(x) max(sapply(1:(nrow(x)-2), function(i) with(x, mean(Amount[i:(i+2)],na.rm=TRUE))))) bmthree and got the following output. $`1971` [1] 70.81667 $`1972` [1] 68.94553 $`1973` [1] 102.7236 $`1974` [1] 73.6625 $`1975` [1]
2010 Feb 28
1
ggplot 'annotate problem' again.
I had a problem annotating a graph last year ( see http://n4.nabble.com/Putting-names-on-a-ggplot-td907158.html#a907158 for the discussion) Stefan (smu) provided a solution using annotate(). However I apparently did not update the graph file and,now, when I go back to the thread and try to use Stefan's solution it does not seem to work although I am sure that it did then. The problem
2012 Aug 06
5
sapply() and by()
Hello everyone, I have a dataset with 5 colums (4 colums with thresholds of weather stations and one with month - data of 5 years). Now I would like to calculate the average for each month. I tried this unsuccessfully: lf.med <- sapply(LF[,1:4],mean,LF[,5]) Error in mean.default(X[[1L]], ...) : 'trim' must be numeric and have length 1 With lf.med <- by(LF[,1:4],LF[,5],mean)
2008 Aug 26
1
processing subset lists and then plot(density())
d <- structure(list(Site = structure(c(8L, 12L, 7L, 6L, 11L, 5L, 10L, 4L, 3L, 2L, 1L, 9L, 8L, 12L, 7L, 6L, 11L, 5L, 10L, 4L, 3L, 2L, 1L, 9L, 8L, 12L, 7L, 6L, 11L, 5L, 10L, 4L, 3L, 2L, 1L, 9L, 8L, 12L, 7L, 6L, 11L, 5L, 10L, 4L, 3L, 2L, 1L, 9L, 8L, 12L, 7L, 6L, 11L, 5L, 10L, 4L, 3L, 2L, 1L, 9L, 8L, 12L, 7L, 6L, 11L, 5L, 10L, 4L, 3L, 2L, 1L, 9L, 8L, 12L, 7L, 6L, 11L, 5L, 10L, 4L, 3L, 2L, 1L, 9L,
2011 Jun 13
1
Heatmap in R and/or ggplot2
I have a dataframe df with columns x, y, and height. I want to create a heatmap-like plot that creates a grid of x by y, and then color codes the grid depending on the value of height. Is there a ggplot2 object to do this? I'm able to easily do this in Excel with pivot tables and conditional formatting so I'm including an image that is close to the output I want. I want to be able to
2009 Nov 26
1
lattice --- different properties of lines corresponding to type=c("l", "a") respectively
I think the subject says it all. I want to make a simple lattice plot, using xyplot with the argument type=c("l","a"). The problem then is that in the resulting plot it is difficult/impossible to see which plot corresponds to the average and which to the individual profiles. I triedthings like extra arguments lwd=c(1,3) or col=c("blue","red") hoping
2008 Jun 04
1
dotchart
I am trying to plot the following data using dotchart intersect.data<-structure(list(X = structure(c(1L, 3L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L, 2L, 4L, 5L, 6L, 7L), .Label = c("1-100", "1001-1100", "101-200", "1101-1200", "1201-1300", "1301-1400", "1401-1500", "201-300", "301-400", "401-500",
2008 Jul 06
2
lattice question
I'm creating a lattice barchart based off a pretty complicated data structure. The barchart comes out quite nice ( thanks to lattice ) but the problem is that the horizontal axis comes out all scrunched because the barchart doesn't know that the intervals of Var.1 are really "associated" with the conditioning variable Var.2. Therefore, all the intervals of Var.1 are put on
2009 May 15
1
data summary and some automated t.tests.
I would like to preform a t.test to each of the measured variables (sand.silt etc.) with a mean and sd for each of the treatments (up or down), and out put this as a table.... I am having a hard time starting- maybe it is to close to lunch. Any suggestions would be greatly appreciated. Stephen Sefick x <- (structure(list(sample. = structure(c(1L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 2L, 3L,
2018 May 16
1
Systemfit Question
I can't get my simultaneous equations to work using system fit. Please help. #Reproducible script Empdata<- read.csv("/Users/ngwinuiazenui/Documents/UPLOADemp.csv") View(Empdata) str(Empdata) Empdata$gnipc<-as.numeric(Empdata$gnipc) install.packages("systemfit") library("systemfit") pdata <- plm.data(Empdata,
2008 Dec 02
1
ggplot2 facet_wrap problem
Hadley, I don't know if I am doing something wrong or if it is ggplot please see the two graphs at the bottom of the page (code). melt.nut <- (structure(list(RiverMile = c(119L, 119L, 119L, 119L, 119L, 119L, 119L, 119L, 119L, 148L, 148L, 148L, 148L, 148L, 148L, 148L, 179L, 179L, 179L, 179L, 179L, 179L, 179L, 185L, 185L, 185L, 185L, 185L, 185L, 185L, 190L, 190L, 190L, 190L, 190L, 190L,
2017 Aug 23
2
strange nlme augpred behaviour
Dear all I encountered strange behaviour of augPred with virtually the same data First I made groupedData object. > mar.g<-groupedData(rutilizace~doba|int, data=mar) When I perform nlme on complete dataset I get an error with augPred > fit<-nlsList(rutilizace~SSasymp(doba, Asym, R0, lrc), data=mar.g) Warning message: c("1 error caught in nls(y ~ cbind(1 - exp(-exp(lrc) * x),
2011 May 18
1
Multiple plots on one device using stl
G'day, I am looking at monthly reports, and have three series of monthly data from 2007 to 2009. I would like to show the season decomposition of these two series side by side on the one device, however using plot doesn't seem to respect any use of layout(matrix(1:3, ncol=3)) or par(mfcol=c(1,3)). I'm guessing that this means that the plot(stl) perhaps uses them, but I can't find
2017 Aug 23
0
strange nlme augpred behaviour
Better posted on r-sig-mixed-models , no? Cheers, Bert Bert Gunter "The trouble with having an open mind is that people keep coming along and sticking things into it." -- Opus (aka Berkeley Breathed in his "Bloom County" comic strip ) On Wed, Aug 23, 2017 at 5:17 AM, PIKAL Petr <petr.pikal at precheza.cz> wrote: > Dear all > > I encountered strange
2013 Oct 30
1
disculpe las molestias ...ayuda con MICE
Muchas gracias, pero claro en una muestra de 50 datos se ejecuta, en la muestra original de 1000 registros me tira error :( 2013/10/30 daniel <daniel319@gmail.com> > Amalia, > > No obtengo tus resultados. Corrí tus formulas y datos y el resultado es > x <- structure(list(ï..psraid = c(202517L, 202518L, 202520L, 202523L, > + 202527L, 202537L, 202543L, 202544L, 202551L,
2016 Apr 22
1
Unique Ordering
Hi R-Help, data at bottom I've been struggling with a problem where I need to order based on 1) the Frequency "Freq" and 2) keeping each group of 3 of the same type together "Var2" but I want across all groups it to go "high to low" based on the earn factor. Thank you! structure(list(Var1 = structure(c(1L, 3L, 2L, 1L, 2L, 3L, 1L, 3L, 2L, 3L, 1L, 2L, 3L, 1L,
2017 Aug 23
2
strange nlme augpred behaviour
Hi Well, yes I tried it about two weeks ago but my post did not get through as it still awaits moderator approval. I could check which column is offending but actually it is only minor nuisance, I can live with selection of columns before fitting a model. What seems to me strange is that both full dataset and only selected colums gave me identical fit results but only one works within augPred.
2018 Feb 22
0
alternative for multiple if_else statements
I don't fully understand the logic you are trying to implement, but something along the lines of foo <- cut(trialData$date, breaks = as.Date(c("2007-01-01", "2008-05-01", "2009-04-01", "2010-05-01",