Displaying 20 results from an estimated 2000 matches similar to: "Problem with Trellis graphics in nlme"
2002 Feb 04
2
Help with accessing elements of a list
Hi,
As part of the analysis of a longitudinal study, I have a list, called wg,
on R 1.3.1 for windows created as follows -
wg <- by(xx, xx$mrn, function(xx) lm(xx$maternal.wt ~ xx$gestation,
data=xx))
xx is a data.frame, and so wg contains the results of 293 linear
regressions, as lm objects.
Now what I want is to extract the 293 intercepts and regression coefficients
as a vector, and
2006 Jan 11
3
how to obtain "par(ask=TRUE)" with trellis-plots
Dear alltogether,
how can a delay like possible with par(ask=TRUE) be attained while using
trellis-plots within a loop or something like that?
the following draws each plot without waiting for a signal
(mouse-klick), so par() does not work for that:
library(nlme)
for(i in 1:3)
{
fitlme <- lme(Orthodont)
par(ask=TRUE) # does not work with trellis....
print(
2010 Aug 04
4
Passing the name of a variable to a function
Dear colleagues,
I have a problem which has bitten me occasionally. I often need to
prepare graphs for many variables in a data set, but seldom for all.
or for any large number of sequential or sequentially named variables.
Often I need several graphs for different subsets of the dataset
for a given variable. I run into similar problems with other needs
besides graphing.
What I would like to
2018 Apr 18
3
Problem with regression line
Hello,
I am trying to graph a regression line using the followings:
Age <- c(39, 47, 45, 47, 65, 46, 67, 42, 67, 56, 64, 56, 59, 34, 42, 48, 45,
17, 20, 19, 36, 50, 39, 21, 44, 53, 63, 29, 25, 69)
BloodPressure <- c(144, 220, 138, 145, 162, 142, 170, 124, 158, 154, 162,
150, 140, 110, 128, 130, 135, 114, 116, 124, 136, 142, 120, 120, 160, 158,
144, 130, 125, 175)
SimpleLinearReg1=lm(Age ~
2010 Nov 04
5
Logical vectors
Hi folks,
Pls help me to understand follow;
An Introduction to R
2.4 Logical vectors
http://cran.r-project.org/doc/manuals/R-intro.html#R-and-statistics
1)
> x
[1] 1 2 3 4 5
> temp <- x != 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
>
2)
> x
[1] 1 2 3 4 5
> temp <- x > 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
Why NOT
> temp
[1] TRUE FALSE FALSE FALSE
2010 Nov 04
5
Logical vectors
Hi folks,
Pls help me to understand follow;
An Introduction to R
2.4 Logical vectors
http://cran.r-project.org/doc/manuals/R-intro.html#R-and-statistics
1)
> x
[1] 1 2 3 4 5
> temp <- x != 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
>
2)
> x
[1] 1 2 3 4 5
> temp <- x > 1
> temp
[1] FALSE TRUE TRUE TRUE TRUE
Why NOT
> temp
[1] TRUE FALSE FALSE FALSE
2005 Oct 14
1
Predicting classification error from rpart
Hi,
I think I'm missing something very obvious, but I am missing it, so I
would be very grateful for help. I'm using rpart to analyse data on
skull base morphology, essentially predicting sex from one or several
skull base measurements. The sex of the people whose skulls are being
studied is known, and lives as a factor (M,F) in the data. I want to
get back predictions of gender, and
2018 Apr 18
0
Problem with regression line
Hi, Anne,
assign Age and Bloodpressure in the correct order
to the axes in your call to plot as in:
plot(y = Age, x = BloodPressure)
abline(SimpleLinearReg1)
Hth -- Gerrit
---------------------------------------------------------------------
Dr. Gerrit Eichner Mathematical Institute, Room 212
gerrit.eichner at math.uni-giessen.de Justus-Liebig-University Giessen
Tel:
2018 Jan 17
0
effects & lme4: error since original data frame notfoundWASeffects: error when original data frame is missing
Dear Gerrit,
This issue is discussed in a vignette in the car package (both for functions in the car and effects packages): vignette("embedding", package="car") . The solution suggested there is the essentially the one that you used.
I hope this helps,
John
-----------------------------
John Fox, Professor Emeritus
McMaster University
Hamilton, Ontario, Canada
Web:
2006 Apr 23
1
Comparing GLMMs and GLMs with quasi-binomial errors?
Dear All,
I am analysing a dataset on levels of herbivory in seedlings in an
experimental setup in a rainforest.
I have seven classes/categories of seedling damage/herbivory that I want to
analyse, modelling each separately.
There are twenty maternal trees, with eight groups of seedlings around each.
Each tree has a TreeID, which I use as the random effect (blocking factor).
There are two
2018 Jan 17
0
effects & lme4: error since original data frame not found WASeffects: error when original data frame is missing
Hi, again,
I have to modify my query since my first (too simple)
example doesn't reflect my actual problem. Second try:
When asking Effect() inside a function to compute an effect
of an lmer-fit which uses a data frame local to the body of
the function, as in the following example (simplifying my
actual application), I get the "Error in is.data.frame(data) :
object 'X' not
2018 Jan 17
4
effects: error when original data frame is missing
Hello, everyody,
when asking, e.g., Effect() to compute the effects of a fitted,
e.g., linear model after having deleted the data frame from the
workspace for which the model was obtained an error is reported:
> myair <- airquality
> fm <- lm(Ozone ~ Temp, data = myair)
> rm(myair)
> Effect("Temp", fm)
Error in eval(model$call$data, envir) : object 'myair'
2005 Mar 22
2
lattice xyplot() postscript (?) problem in R 2.0.0
Dear all,
I work with R Version 2.0.0 on
Machine hardware: sun4u
OS version: 5.9
Processor type: sparc
Hardware: SUNW,Sun-Blade-1000
and I have a very simple data frame (called OR) with the following
variables:
> sapply( OR, class)
X ci FTyp
"factor" "numeric" "factor"
(In OR$ci there are some Inf-values. OR's
2012 Mar 27
2
Supperscript, subscript and double lines in the main/sub title and using greek letters
Dear R-help,
I am trying to express myself as best as I can here. If you also use Latex
to edit math reports or other languages with similar editing method,
you'll see what I'm talking about. My sincere appologies if my question is
not clear enough to some extend, as also I'm not able to provide my code
here because I don`t know which one I can use...
When editing the title in R
2011 Jan 05
3
Advice on obscuring unique IDs in R
Dear colleagues,
This may be a question with a really obvious answer, but I
can't find it. I have access to a large file with real
medical record identifiers (mixed strings of characters and
numbers) in it. These represent medical events for many
thousands of people. It's important to be able to link
events for the same people.
It's much more important that the real record numbers
2008 Jul 18
2
column wise paste of data.frames
Hi everybody!
I'm sure that I overlook something and feel quite stupid to ask, but I
have not found an easy solution to the following problem: Take e.g. the
Orthodont data from the nlme package:
> head(Orthodont)
Grouped Data: distance ~ age | Subject
distance age Subject Sex
1 26.0 8 M01 Male
2 25.0 10 M01 Male
3 29.0 12 M01 Male
4 31.0 14 M01 Male
2010 Jun 22
2
xyplot: adding pooled regression lines to a paneled type="r" plot
Consider the following plot that shows separate regression lines ~ age
for each subject in the Pothoff-Roy Orthodont data,
with separate panels by Sex:
library(nlme)
#plot(Orthodont)
xyplot(distance ~ age|Sex, data=Orthodont, type='r', groups=Subject,
col=gray(.50),
main="Individual linear regressions ~ age")
I'd like to also show in each panel the pooled OLS
2002 Jan 09
1
value labels from read.spss()?
>From owner-r-help at stat.math.ethz.ch Wed Jan 9 10:08:44 2002
>
>Does anyone know how to access/list the value labels stored in a SPSS .sav
>file?
>At the moment I can read in variables using read.spss() (foreign package),
>but have to power up SPSS to check value labels.
>
>Stuart
There may be a solution to this in R, and I would love to hear
it, but I was just faced
2006 Jul 18
1
Classification error rate increased by bagging - any ideas?
Hi,
I'm analysing some anthropometric data on fifty odd skull bases. We know the
gender of each skull, and we are trying to develop a predictor to identify
the
sex of unknown skulls.
Rpart with cross-validation produces two models - one of which predicts
gender
for Males well, and Females poorly, and the other does the opposite (Females
well, and Males poorly). In both cases the error
2011 Nov 19
1
Advice on recoding a variable depending on another which contains NAs
Dear colleagues,
I would be very grateful for your help with the following. I
have banged my head off this question several times in the
past, and repeatedly over the last week. I have looked in
the usual places and found no obvious solution. I fear that
this just means I didn't recognize it, but I'd be very
grateful for your help.
I am scoring 8000 psychometric tests - the SCQ, if