Displaying 20 results from an estimated 2000 matches similar to: "Minimizing Computational Time"
2013 Mar 11
2
vertical lines in R plot
Dear All,
May I seek your suggestion on a simple issue. I want to draw vertical lines
at some positions in the following R plot. To be more specific, I wish to
draw vertical lines at d=c(5.0,5.5,6) and they should go till
p=c(0.12,0.60,0.20) . I haven't found any way out, though made several
attempts. Please run the following commands first if you are interested in!
2012 Oct 02
3
Integration in R
Dear R-users,
I am facing problem with integrating in R a likelihood function which is a
function of four parameters. It's giving me the result at the end but
taking more than half an hour to run. I'm wondering is there any other
efficient way deal with. The following is my code. I am ready to provide
any other description of my function if you need to move forward.
2009 Jul 01
2
Difficulty in calculating MLE through NLM
Hi R-friends,
Attached is the SAS XPORT file that I have imported into R using following code
library(foreign)
mydata<-read.xport("C:\\ctf.xpt")
print(mydata)
I am trying to maximize logL in order to find Maximum Likelihood Estimate (MLE) of 5 parameters (alpha1, beta1, alpha2, beta2, p) using NLM function in R as follows.
# Defining Log likelihood - In the function it is noted as
2005 Feb 27
2
Help with constrained optimization
Dear all,
I need an advice in the following problem.
I have to maximize two functions of the form f1(x)=f(y1,x,alpha1,beta1) and f2(x)=(y2,x,alpha2,beta2), the maximization is with respect to alpha1, alpha2, beta1, beta2. I can maximize each function separately using nlm.
The problem is that I have to add the constraint of the form g(alpha1)=g(alpha2).
The total number of parameters is
2012 Mar 19
1
Linear regression
Hello there,
I am new to using regression in R. I wanted to solve a simple regression
problem where I have 2 equations and 2 unknowns.
So lets say -
y1 = alpha1*A + beta1*B
y2 = alpha2*A + beta2*B
y1 <- runif(100000, 0,1)
y2 <- runif(100000,0,1)
alpha1 <- 0.6
alpha2 <- 0.75
beta1 <- 1-alpha1
beta2 <- 1-apha2
I now want this equation to estimate the values of A and B. Both A
2005 Mar 02
1
Warning: number of items to replace is not a multiple of replacement length
I feel like a complete dolt, as I know this question has been asked by
others on a fairly regular basis, but I'm going in circles trying to get
the following to work:
id.prob<-function (tt)
{
library(mvtnorm)
#============================
Makeham<-function(tt)
{
a2=0.030386513
a3=0.006688287
b3=0.039047537
t<-tt-20
h.t<-a2+a3*exp(b3*t)
S.t<-exp(-a2*t+a3/b3*(1-exp(b3*t)))
2008 Jan 04
2
R2WinBUGS sending variables as factors
Hello R and BUGS users,
I am writing a heirarchical model in R to send to BUGS via R2WinBUGS and
I am finding it difficult to get the model to run. I seem to be having
two problems.
1) I can't seem to send variables classed as factors (Month), is there a
way do this?
2) Checking the Log in WinBUGS I can see that the model is Syntactically
correct, but Bugs is not able to recognise the the
2011 Aug 11
1
R crashes when communicating with JAGS
There is a thread on this topic already:
http://finzi.psych.upenn.edu/Rhelp10/2010-August/250934.html
I'm rather mystified by a similar problem and wondering whether I've
overlooked something obvious. I'm running with latest versions of R and
all packages, and latest version of JAGS running under Windows 7.
Here's the problem. I have some source code. It's given below -
2003 Dec 18
1
NUMERIC DERIVATE
UseRs,
I used the optim function
valor.optim <- optim(c(1,1,1),logexp1,method
="BFGS",control=list(fnscale=-1),hessian=T);
and I want to calculate the derivates,
psi1<-valor.optim$par[1]
psi2<-valor.optim$par[2]
psi3<-valor.optim$par[3]
a0=exp(psi1);
a1=exp(psi2)/(20+exp(psi2)+exp(psi3));
a2=exp(psi3)/(20+exp(psi2)+exp(psi3))
2006 Jul 22
1
ifelse command
Dear:
I try to revise the maximum likelihood function below using something constrains. But it seems something wrong with it. Becasue R would not allow me to edit the function like this. It is very appreciate if you can help.
function (parameters,y,x1,x2)
{
p<-parameters[1]
alpha1<-parameters[2]
beta1<-parameters[3)]
delta1<-parameters[4]
alpha2<-parameters[5]
2006 Jul 22
1
Why the contrain does not work for selecting a particular range of data?
Dear:
Continuing the issue of 'ifelse'! I selecting the data whose 'x2'=1 for maximizing likelihood. I used two way to do this but the results are different.
1.Way one I use the data for x2=1 and run the program. It works for me. Tthe program is described as below:
function (parameters,y1,x11)
{
p<-parameters[1]
alpha1<-parameters[2]
beta1<-parameters[3]
2007 Jun 27
1
SEM model fit
I wonder if someone could explain why, when I perform confirmatory
factor-analysis model using polychoric correlations why I do not get an
estimated confidence interval for the RMSEA. My experience with these type
models is that I would obtain a confidence interval estimate. I did not get
any warning messages with the output.
RESULTS:
Model Chisquare = 1374 Df = 185 Pr(>Chisq) = 0
2004 Jun 22
2
function not in load table
Hi,
I apologize for this often/old question. I found some hints but couldn't
solve the problem so far.
I have C functions (incl. the header files) as well as the R wrapper
functions which I want to use for faster calculations. These functions
are included in a R package.
The installation process seems to be ok (no errors). I also can load the
package without errors. But when I call the
2005 Sep 14
2
SSL/TLS stopped working in 1.0 alpha2
I have both 1.0 alpha1 and alpha2 installed on my test mail server.
SSL/TLS does not work on alpha2. I'm using the same config file for
both. No errrors in dovecot.log either. Is there a way to increase
debugging info without recompiling?
2007 Jul 26
2
error in using R2WinBUGS on Ubuntu 6.10 Linux
I am trying to run WinBUGS 1.4 from the Ubuntu 6.10 Linux distribution. I am using the R2WinBUGS packages with the source file listed below. WinBUGS appears to run properly, but I get the following message after WinBUGS starts in WINE. Does anyone know what may be causing this error and what the correction may be?
Thanks
ERROR MESSAGE:
fixme:ole:GetHGlobalFromILockBytes cbSize is 13824
2009 Nov 24
1
Titles in plots overlap
Hi,
I use fCopulae package to draw different graphs of univariate and bivariate skew t. But the plots titles overlap. I tried using cex.main, font.main to adjust the size but they still overlaps. Here is my code:
par(mfrow = c(3, 1))
mu = 0
Omega = 1
alpha1 = 0
alpha2 = 1.5
alpha3 = 2
alpha4 = 0.5
Z1 = matrix(dmvst(x, 1, mu, Omega, alpha1, df = Inf), length(x))
Z2 = matrix(dmvst(x, 1, mu,
2013 Jul 22
1
Error with sem function df = -6
Hello all,
I have an issue where I am generating data and trying to confirm the
estimates using a sem. I keep getting an error about the degree of freedom
being negative "Error in sem.default(ram, S = S, N = N, raw = raw, data =
data, pattern.number = pattern.number, : The model has negative degrees of
freedom = -6"
Can someone explain this error or tell me what is wrong with my
2004 May 06
5
Orthogonal Polynomial Regression Parameter Estimation
Dear all,
Can any one tell me how can i perform Orthogonal
Polynomial Regression parameter estimation in R?
--------------------------------------------
Here is an "Orthogonal Polynomial" Regression problem
collected from Draper, Smith(1981), page 269. Note
that only value of alpha0 (intercept term) and signs
of each estimate match with the result obtained from
coef(orth.fit). What
2009 Oct 23
3
v2.0.alpha2 released
http://dovecot.org/releases/2.0/alpha/dovecot-2.0.alpha2.tar.gz
http://dovecot.org/releases/2.0/alpha/dovecot-2.0.alpha2.tar.gz.sig
Changes since alpha1:
- All debug messages are now logged to debug log (debug_log_path
setting, defaults to info_log_path). Patch by Pascal Volk.
- Added support for SORT=DISPLAY IMAP extension.
- Added doveadm who command for listing currently logged in users.
2013 Jan 11
1
problems with package 'segmented'
Dear R-users,
I am trying to understand how the 'segmented'-package works to determine
breakpoints and slopes of regression lines in broken-line regression models.
However, I am not able to repeat the example on the "plant"-dataset,
which was reported in the accompanying paper of the package. (V.M.R
Muggeo, "Segmented: an R package to fit regression models with