Displaying 20 results from an estimated 1000 matches similar to: "help with constrOptim function"
2004 Oct 04
3
(off topic) article on advantages/disadvantages of types of SS?
Hello. Please excuse this off-topic request, but I know that the
question has been debated in summary form on this list a number of
times. I would find a paper that lays out the advantages and
disadvantages of using different types of SS in the context of
unbalanced data in ANOVA, regression and ANCOVA, especially including
the use of different types of contrasts and the meaning of the
2004 Apr 26
2
mixed model with binomial link?
Hello. I have to fit a mixed model from a repeated measures split-plot
experiment in which the response variable is binary. This requires a
generalised linear mixed model in which I can specify a binomial
distribution. I can’t find the appropriate package in R. I have looked
at glmmML, but it doesn’t seem to allow any mixed structure beyond a
simple 2-level one. Can anyone point me to the
2004 Sep 30
1
histograms with more than one variable
Hello. I want to plot the distribution of a continuous variable (y) in
each of two groups on the same graph as histograms. I suppose one could
call this a 2-d histogram? Can this be done in R? Here is a typical
data.set:
y group
1.2 1
3.3 1
2.4 2
5.7 1
0.2 2
etc.
Bill Shipley
Subject Matter Editor, Ecology
North American Editor, Annals of
2003 Dec 11
2
typeIII SS for lme?
To avoid angry replies, let me first say that I know that the use of
Type III sums of squares is controversial, and that some statisticians
recommend instead that significance be judged using the non-marginal
terms in the ANOVA. However, given that type III SS is also demanded by
some… is there a function (equivalent to drop1 for lm) to obtain type
III sums of squares for mixed models using the
2003 Oct 28
1
setting up complicated ANOVA in R
Hello. I am about to do a rather complicated analysis and am not sure
how to do it. The experiment has a split-plot design and also repeated
measures. Both of these complications require one to define an error
term and it seems that one cannot specify two such terms. The
split-plot command is:
aov(y~covariates +A*B+Error(C), data=) where A and B are the fixed
effects and C is the
2005 Feb 15
1
shrinkage estimates in lme
Hello. Slope estimates in lme are shrinkage estimates which pull the
OLS slope estimates towards the population estimates, the degree of
which depends on the group sample size and the distance between the
group-based estimate and the overall population estimate. Although
these shrinkage estimates as said to be more precise with respect to the
true values, they are also biased. So there is a
2004 Apr 01
1
nls function
Hello. I am trying to fit a non-rectangular hyperbola function to data
of photosynthetic rate vs. light intensity. There are 4 parameters that
have to be estimated. I find the nls function very difficult to use
because it often fails to converge and then gives out cryptic error
messages. I have tried playing with the control parameters but this
does not always help.
Is there another
2005 Jan 05
1
cubic spline smoother with heterogeneous variance.
Hello. I want to estimate the predicted values and standard errors of
Y=f(t) and its first derivative at each unique value of t using the
smooth.spline function. However, the data (plant growth as a function
of time) show substantial heterogeneity of variance since the variance
of plant mass increases over time. What is the consequence of such
heterogeneity of variance in terms of bias in the
2004 Oct 01
3
controlling colour in Trellis histogram
Hello. I am sorry for posting a (seemingly) simple question, but I have
just spent 2 hours trying to find the answer, without success. I want
to make a histogram with conditioning on a factor, using Trellis
graphics. However, I do not want any colours (only black and white)
either in the histograms or in the strip. There must be some simple
argument but I can’t find it. Here is my code so
2003 Nov 04
3
help with lme()
Hello. I am trying to determine whether I should be using ML or REML
methods to estimate a linear mixed model. In the book by Pinheiro &
Bates (Mixed-effects models in S and S-PLUS, page 76) they state that
one difference between REML and ML is that « LME models with different
fixed-effects structures fit using REML cannot be compared on the basis
of their restricted likelihoods. In
2003 Nov 25
1
using pdMAT in the lme function?
Hello. I want to specify a diagonal structure for the covariance matrix
of random effects in the lme() function.
Here is the call before I specify a diagonal structure:
> fit2<-lme(Ln.rgr~I(Ln.nar-log(0.0011)),data=meta.analysis,
+ random=~1+I(Ln.nar-log(0.0011)|STUDY.CODE,na.action=na.omit)
and this works fine. Now, I want to fix the covariance between the
between-groups slopes
2004 Feb 19
1
controlling nls errors
Hello. I am using the nonlinear least squares function (nls). The
function that I am trying to fit seems to be very sensitive to the
starting values and, if these are not chosen properly, the nls function
stops and gives an error message:
Error in numericDeriv(form[[3]], names(ind), env) :
Missing value or an Infinity produced when evaluating the model
In addition: Warning
2005 Sep 01
1
making self-starting function for nls
Hello. Following pages 342-347 of Pinheiro & Bates, I am trying to
write a self-starting nonlinear function (a non-rectagular hyperbola) to
be used in nonlinear least squares regression (and eventually for a
mixed model). When I use the getInitial function for my self-starting
function I get the following error message:
> getInitial(photo~NRhyperbola(Irr,theta,Am,alpha,Rd),dat)
Error
2004 Jul 16
1
specifying a function in nls
Hello. I am trying to understand the syntax of the nonlinear least
squares function (nls) when the function definition is made outside of
the call. Here is the context.
1. If I specify the following command, it works fine:
> fit2<-nls(
+ A~Am*(1-exp(-alpha*(I-LCP))),data=dat1,
+ start=list(Am=3.6,alpha=0.01,LCP=20))
2. Now, I want to be able to specify the function definition
2006 Apr 13
1
obtaining residuals from lmer
Hello. I cannot find out how to extract the residuals from a mixed model
using the lmer function. Can someone help?
Bill Shipley
North American Editor, Annals of Botany
Editor, "Population and Community Biology" series, Springer Publishing
Département de biologie, Université de Sherbrooke,
Sherbrooke (Québec) J1K 2R1 CANADA
Bill.Shipley@USherbrooke.ca
2006 Feb 16
1
help downloading lme4 from CRAN
Hello. I am having trouble downloading the lme4 package from the CRAN
site. The error is:
> local({a <- CRAN.packages()
+ install.packages(select.list(a[,1],,TRUE), .libPaths()[1],
available=a, dependencies=TRUE)})
trying URL `http://cran.r-project.org/bin/windows/contrib/2.0/PACKAGES'
Content type `text/plain; charset=iso-8859-1' length 26129 bytes
opened URL
downloaded 25Kb
2003 Oct 21
3
explaining curious result of aov
Hello. I have come across a curious result that I cannot explain.
Hopefully, someone can explain this. I am doing a 1-way ANOVA with 6
groups (example: summary(aov(y~A)) with A having 6 levels). I get an F
of 0.899 with 5 and 15 df (p=0.51). I then do the same analysis but
using data only corresponding to groups 5 and 6. This is, of course,
equivalent to a t-test. I now get an F of 142.3
2006 Jun 01
1
help with syntax of nlme function
I am having difficulty understanding the syntax of the nlme() function for
nonlinear mixed models. The data frame is called Marouane.chlorophyll. The
model involves a dependent variable (Absorb) and an independent variable
(Ch.surf), which are both numeric variables in the data frame. The data are
hierarchically grouped as Espece, Plante nested within Espece, and Feuille
nested within Plante
2003 Oct 31
1
constrained nonlinear optimisation in R?
Hello. I have searched the archives but have not found anything. I
need to solve a constrained optimisation problem for a nonlinear
function (“maximum entropy formalism”). Specifically,
Optimise: -1*SUM(p_ilog(p_i)) for a vector p_i of probabilities,
conditional on a series of constraints of the form:
SUM(T_i*p_i)=k_i for given values of T_i and k_i (these are
constraints on
2003 Oct 21
0
summary of "explaining curious results of aov"
Earlier, I had posted the following question to the group :
> Hello. I have come across a curious result that I cannot explain.
> Hopefully, someone can explain this. I am doing a 1-way ANOVA with 6
> groups (example: summary(aov(y~A)) with A having 6 levels). I get an
> F of 0.899 with 5 and 15 df (p=0.51). I then do the same analysis but
> using data only