Displaying 20 results from an estimated 1000 matches similar to: "lattice::xyplot/ggplot2: plotting weighted data frames with lmline and smooth"
2007 May 15
3
qr.solve and lm
Dear R experts,
I have a Matlab code which I am translating to R in order to examine and
enhance it.
First of all, I need to reproduce in R the results which were already
obtained in Matlab (to make sure that everything is correct).
There are some matrix manipulations and '\' operation among them in the
code.
I have the following data frame
> ABS.df
Pro syn
2010 Sep 23
1
How to pass a model formula as argument to with.mids
Hello
I would like to pass a model formula as an argument to the with.mids
function from the mice package. The with.mids functon fits models to
multiply imputed data sets.
Here's a simple example
library(mice)
#Create multiple imputations on the nhanes data contained in the mice
package.
imp <- mice(nahnes)
#Fitting a linear model with each imputed data set the regular way works
2013 Jul 17
2
error message in gev
Hi r-users,
I would like to use gev and my data (annual rainfall ) is as follows:
> head(dat,20) A B C D E F G H I J
1 45.1 41.5 58.5 50.1 46.0 49.1 37.7 49.1 59.8 54.0
2 50.3 39.8 49.4 56.4 49.4 48.8 42.1 49.8 49.4 58.3
3 41.7 39.3 44.6 39.1 35.7 41.5 40.8 40.8 38.5 45.6
4 50.7 33.9 48.4 28.2 35.5 39.1 61.4 17.0 30.7 38.3
5 39.3 30.6 46.9 23.8 25.8
2002 Dec 03
1
Any difference in cbind() b/w SPLus and R??
Dear Experts,
I have a data object named "data.char".
When I use cbind(data.char) in SPlus, I got the following results:
> cbind(data.char)
data.char
data matrix, 2700
excluded list, 3
cluster.var character, 2
strata list, 3
xlog CT
link logit
gpcorr 1
missing.row numeric, 0
zero.row numeric, 22
infile perc.csv
attr(,
2012 Nov 14
2
aggrete data from combination
Dear R users,
A have a dataframe (matrix) with two collumns (plot, and diameter (d)). I
want all diameters values for different combination of plots.
For example I want all d values for all posible combination, 100C2 (all d
values for plot 1 with all d values in the plot 2.......with all d values
from plot 1 with all d values from plot 100, ...... with all d values from
plot 99 with all d values
2017 Jun 08
2
Workspace en Rstudio
Estimados,
Les tengo una pequeña consulta.
Estoy trabajando con ASReml en Rstudio, me encuentro corriendo un modelo
(CHL) para obtener el ANOVA de la interacción de los factores gen x env
CHL<- asreml(fixed= MS~geno:env, random = ~rep, data = index) (interacción)
Sin embargo, cuando ejecuto el modelo, R indica que siguiente mensaje:
Current workspace: 128.000000Mb
Warning message:
Abnormal
2009 Jan 23
1
lattice: reverse order of panel.lmline, panel.smooth
Hi,
is it possible to reverse the order in which panel.lmline() or panel.smooth()
operation in xyplot() ? This type of situation might occur when plotting some
variable with depth, but the relation we want to describe is variable ~
depth, and not depth ~ variable, as the plotting formula would suggest.
# an example:
d <- 1:100
v <- d * rnorm(100)
xyplot(d ~ v, ylim=c(100,0),
2005 Aug 08
1
vector vs array
Hi!
OK, I'm trying to select some "useful outliers" from
my dataset: I defined 11 "treshold" values (1 for each
level of a variable (sampling site) as follows:
tresholds<-function(x)
{
tapply(x,mm$NAME,FUN=mean ,simplify = T, na.rm=T)->med
tapply(x,mm$NAME,FUN=sd ,simplify = T,
na.rm=T)->standev
standev+med
}
tresholds(mm$chl)
Now I'd like to select
2007 Nov 30
1
main plot title
Dear R users,
I am having a problem with the main title of a plot. I have written a
function returning a plot and I would like that the main title of this plot
shows actually the name of the dataset I have used. So, for instance: if my
dataset is called Chl, I would like that my plot to be entitled : "Raw
periodogram of Chl". I know the function "paste". I suppose I would be
2007 Jan 26
1
Form of the equation produced by a GLM with Poisson family and log link function
Hi everyone,
My background is not math and I am trying to figure out exactly what equation to use to map a response variable in GIS based on the coefficients obtained from the GLM and the values of the independent variables in each grid cell of my study area. Most specifically, I want to know how to incorporate the Poisson family and log link function in the equation. I would really appreciate if
2013 Jul 18
1
Bland Altman summary stats for all column combinations
Hello,
I have the following data.frame
structure(list(Study = structure(c(1L, 2L, 3L, 4L, 5L, 6L, 7L,
8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L, 1L,
2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L, 15L,
16L, 17L, 18L, 19L, 1L, 2L, 3L, 4L, 5L, 6L, 7L, 8L, 9L, 10L,
11L, 12L, 13L, 14L, 15L, 16L, 17L, 18L, 19L, 1L, 2L, 3L, 4L,
5L, 6L, 7L, 8L, 9L, 10L, 11L, 12L, 13L, 14L,
2011 Oct 12
1
NOTE: unstated dependencies in examples
Using R 2.13.1, I am now getting the following NOTE when I run R CMD
check on my HistData
package
* checking for unstated dependencies in examples ... NOTE
'library' or 'require' calls not declared from:
gplots sp
Under R 2.12.x, I didn't get these notes.
I have ~ 25 .Rd files in this package, and AFAICS, every example uses
library or require for the
functions used;
2006 Apr 14
1
okay, working, but not quite pretty...
Hi all. I got my previous problem fixed. Effective uid and gid fix in
dovecot.conf file made it work. However, I'm still seeing this in
my /var/log/dovecot.conf
dovecot: 2006-04-13 21:09:00 Info: imap(chl at iaminla.com): Effective
uid=1000, gid=1000
The uid and gid *should* both be 1009, and I can't for the life of me
figure out how to configure that. I looked around the list and
2009 Oct 30
1
.Rprofile replacement function setwd() causing errors
In my .Rprofile I have the following functions which display the
current directory in the main R window title bar,
and modify base::setwd() to keep this up to date. I like this because I
can always tell where I am in the file system.
cd <- function(dir) {
base::setwd(dir)
utils::setWindowTitle( short.path(base::getwd()) )
}
short.path <- function(dir, len=2) {
np
2009 Nov 04
0
Weird errors with R CMD check/ggplot2 in examples: how to debug?
[Environment: WinXp, R 2.9.2, all packages up to date; building under
(StatET 0.8, eclipse 3.5.1) or from a batch file]
I'm in the process of creating a package, HistData, on R-forge,
containing interesting data sets
from the history of statistics and data visualization. It contains
several examples that use ggplot2,
which I've declared as a Suggests: in the DESCRIPTION file. The
2004 Mar 01
6
How to plot Histogram with frequence overlaid by distribution curve
Hi,
I am facing the problem that I want to plot a histogram chart set
freq to true and overlay with normal or weibull or exponential distribution
curve.
The sample code is shown as below:
>samp<-c(-8.2262,-8.2262,-8.2262,-8.20209,-8.09294,-8.07321,-8.07321,
-8.07321,-8.07175,-8.04948,-8.04948,-8.04948,-8.03848,-8.03848,
2013 Mar 05
1
Reading Wyoming radiosonde data files with RadioSonde package
Hi,
I need to do some analysis on historic daily radiosonde data I download
from the Wyoming Univ. web page (
http://weather.uwyo.edu/upperair/sounding.html).
I am trying to use the RadioSonde package (V 1.3), but the format of the
files from Wyoming don't match what RadioSonde is expecting.
Has anyone used the Radiosonde package on the Wyoming data?
Here is a sample of the Wyoming file
2009 Sep 28
1
xyplot & lmline: error message.
Hi, I am trying to produce an xyplot with a regression line. The data should
be represented as log/log but when I fit the lmline I receive an error
message - the plot is fine without the log transformation, but the then the
plot is meaningless. I know it must be something simple, but I just can't
see it. Hope someone can help...
Thanks.
xyplot(log(Pk)~log(k),data=rwpk,cex=1,
2012 Oct 30
1
Is there an lm() equivalent of panel.lmline()?
panel.lmline returns intercept and slope of y ~ x subsetted to the
combination of conditioning factors given to xyplot in lattice.
for instance:
xyplot(Xvalues ~ log(Qvalues)|Tfac, data = df7, panel = panel.lmline)
I am looking to find the equivalent formulation for lm() proper. If I do
this:
lmcal <- lm(Xvalues ~ log(Qvalues):Tfac, data = df7)
Only one value of the intercept is returned.
2005 Mar 17
0
xyplot w/ panel.lmline "solution"
Dear Sebastian Luque (and All R Users)
With the following code I managed to plot different characters and regression
lines for panels 2 ("Day of year 101") and >4 ("Days of year" 151, 157 and
172):
xyplot(log(no.larvae)~age.cls|factor(day),data=mortal,
layout=c(7,1),aspect=5/3,
xlab="Age class (d)",ylab="Ln(Abundance)",