Displaying 20 results from an estimated 8000 matches similar to: "variance of combinations of means - off topic"
2009 Oct 24
1
dev.copy(postscript,...) generates a disrupted string
Dear R-Users,
I have the following problem: I would like to create a postscript file
containing an r-plot with the string "\\vartheta" in it (reason: this
is later converted to the TeX-string "\vartheta" and a vartheta is
printed in the figure). In the minimal example below, the problem is
that the created postscript file does _not_ contain the string "\\vartheta
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
2008 Dec 27
1
indexed expression
Hello expeRts,
I need generate symbolize the autocovariances matrix of a Gaussian
ARMA(1,1), for derivate it and evaluate.
I try this codes, but whitout sucess
vacv<-NULL
vacv[1]<-1-2*phi*theta-theta^2
vacv[2]<-(1-phi*theta)*(phi-theta)
vacv[3:n]<-acv[2]*(phi^(1:(n-2)))
facv<-list()
for(i in 1:2)
2005 Oct 26
1
help with a self-starting function in nonlinear least squares regression.
Hello. I am having a problem setting up a self-starting function for
use in nonlinear regression (and eventually in the mixed model version).
The function is a non-rectangular hyperbola - called "NRhyperbola" -
which is used for fitting leaf photosynthetic rate to light intensity.
It has one independent variable (Irr) and four parameters (theta, Am,
alpha and Rd). I have created this
2005 Oct 27
1
syntax of nlme with nesting
This may appear too elementary to some on this list, but not to me. My
apologies if this is the case. I have mastered the lme function but the
nlme function has me stumped.
I am attempting to fit a nonlinear mixed model with 4 levels of nesting.
I am getting a cryptic error message and do not know what is wrong with
the syntax of the call. This is the call:
>
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 Nov 09
1
strategies to obtain convergence using nlme
Hello. I am working on an analysis involving the nonlinear mixed model
function (nlme) in R. The data consist of measures of carbon fixation
by leaves as a function of light intensity and the parametric function
(standard in this area because it has a biological interpretation) is a
non-rectangular hyperbola. I cannot get the nonlinear mixed model
(nlme) function to converge cleanly. I am
2011 Nov 17
3
Obtaining a derivative of nls() SSlogis function
Hello, I am wondering if someone can help me. I have the following function
that I derived using nls() SSlogis. I would like to find its derivative. I
thought I had done this using deriv(), but for some reason this isn't
working out for me.
Here is the function:
asym <- 84.951
xmid <- 66.90742
scal <- -6.3
x.seq <- seq(1, 153,, 153)
nls.fn <- asym/((1+exp((xmid-x.seq)/scal)))
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
2020 Oct 25
2
Ubuntu 20.10
Hi Dirk,
I didn't capture the output but using Focal I got an error with RcppParallel trying to open a file that wasn't found, and plotly::ggplot() would not render a ggplot graph.
20.10 is working well for me otherwise.
Frank
http://fharrell.com
http://biostat.mc.vanderbilt.edu/FrankHarrell
Twitter: @f2harrell
---- On Sun, 25 Oct 2020 11:52:43 -0500
2007 Oct 22
3
Elasticity in Leslie Matrix
Dear R-users,
I would like to calculate elasticities and sensitivities of each parameters
involved in the following transition matrix:
A <- matrix(c(
sigma*s0*f1, sigma*s0*f2,
s, v
), nrow=2, byrow=TRUE,dimnames=list(stage,stage))
The command "eigen.analysis" avaliable in package "popbio" provides
sensibility matrix and elasticity matrix
2007 Jan 04
9
setting new working directories
Hello, and Happy New Year. My default working directory is getting very
cluttered. I know that I should be using a different working directory for
each project (I work in Windows), but do not know how to go about creating
different ones and moving back and forth between them. I have read Venables
& Ripley (Modern Applied Statistics with S-PLUS, 1994) but this seems out of
date with respect
2020 Oct 26
2
Ubuntu 20.10
Hi Dirk,
One side observation: r-cran debian now seems to be in Ubuntu 20.10 Universe so I don't need to add the repo any more.
Here is a reproducible example that fails with the latest r-cran-rcppparallel but works when I manually install the source package:
require(rstan)
stancode <- 'data {real y_mean;} parameters {real y;} model {y ~ normal(y_mean,1);}'
mod <-
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
2010 Jun 02
1
Use apply only on non-missing values
I have a function that I am currently using very inefficiently. The following are needed to illustrate the problem:
set.seed(12345)
dat <- matrix(sample(c(0,1), 110, replace = TRUE), nrow = 11, ncol=10)
mis <- sample(1:110, 5)
dat[mis] <- NA
theta <- rnorm(11)
b_vector <- runif(10, -4,4)
empty <- which(is.na(t(dat)))
So, I have a matrix (dat) with some values within the matrix
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
2009 Mar 12
3
avoiding termination of nls given convergence failure
Hello. I have a script in which I repeatedly fit a nonlinear regression to
a series of data sets using nls and the port algorithm from within a loop.
The general structure of the loop is:
for(i in 1:n){
… extract relevant vectors of dependent and independent variables …
… estimate starting values for Amax and Q.LCP…
2010 Aug 04
4
Adding collumn to existing data frame
Hi experts,
I am trying to write a very flexible method that allows me to add a
new column to an existing data frame. This is what I have so far:
add.column <- function(df, new.col, name) {
n.row <- dim(df)[1]
length(new.col) <- n.row
names(new.col) <- name
return(cbind(df, new.col))
}
df <- NULL
df <- data.frame(a=c(1,2,3))
df
# corect: added NA to new collumn
df <-
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 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