Displaying 17 results from an estimated 17 matches similar to: "Using MLE on a somewhat unusual likelihood function"
2017 Nov 07
0
Using MLE on a somewhat unusual likelihood function
(inline)
> On 7 Nov 2017, at 06:02 , Hugo Andr? <karlhugoandre at gmail.com> wrote:
>
> So I am trying to use the mle command (from stats4 package) to estimate a
> number of parameters using data but it keeps throwing up this error message:
>
> Error in solve.default(oout$hessian) :
> Lapack routine dgesv: system is exactly singular: U[1,1] = 0
>
> This error
2007 Oct 31
1
Simple Umacs example help..
Hello all...
I am just starting to teach myself Bayesian methods, and am
interested in learning how to use UMacs. I've read the
documentation, but the single example is a bit over my head at the
level I am at right now. I was wondering if anyone has any simple
examples they'd like to share. I've successfully done a couple of
simple gibbs examples, but have had a hard time
2019 Feb 01
3
nlminb with constraints failing on some platforms
Hello,
R 3.5.2 on ubuntu 18.04. sessionInfo() at the end.
Works with me, same results, cannot reproduce the error.
f <- function(x) sum( log(diff(x)^2+.01) + (x[1]-1)^2 )
opt <- nlminb(rep(0, 10), f, lower=-1, upper=3)
str(opt)
xhat <- rep(1, 10)
all.equal(opt$par, xhat, tol=0) # good: 5.53 e-7
#[1] "Mean relative difference: 5.534757e-07"
all.equal(opt$objective,
2019 Jan 28
8
nlminb with constraints failing on some platforms
I've noticed unstable behavior of nlminb on some Linux systems. The problem can be reproduced by compiling R-3.5.2 using gcc-8.2 and running the following snippet:
f <- function(x) sum( log(diff(x)^2+.01) + (x[1]-1)^2 )
opt <- nlminb(rep(0, 10), f, lower=-1, upper=3)
xhat <- rep(1, 10)
abs( opt$objective - f(xhat) ) < 1e-4 ## Must be TRUE
The example works perfectly when
2019 Feb 01
0
nlminb with constraints failing on some platforms
No error on Windows 10, R.3.5.2 patched, Rblas compiled with OpenBLAS
0.20, Rlapack is base.
> f <- function(x) sum( log(diff(x)^2+.01) + (x[1]-1)^2 )
> opt <- nlminb(rep(0, 10), f, lower=-1, upper=3)
> str(opt)
List of 6
$ par : num [1:10] 1 1 1 1 1 ...
$ objective : num -41.4
$ convergence: int 0
$ iterations : int 66
$ evaluations: Named int [1:2] 96 830
..-
2019 Feb 01
1
nlminb with constraints failing on some platforms
> On 1 Feb 2019, at 10:00, Martin Maechler <maechler at stat.math.ethz.ch> wrote:
>
> ........
>>> sessionInfo()
>> R version 3.5.2 (2018-12-20)
>> Platform: x86_64-pc-linux-gnu (64-bit)
>> Running under: Scientific Linux release 6.4 (Carbon)
>
>> Matrix products: default
>> BLAS/LAPACK:
2006 Sep 11
2
faster way?
Hi,
Is there a faster way to do this? It takes forever, even on a
moderately sized dataset.
n <- dim(dsn)[1]
dsn2 <- dsn[order(-dsn$xhat),]
dsn2[1, "cumx"] <- dsn2[1, "xhat"]
for (i in 2:n) {
dsn2[i, "cumx"] <- dsn2[i - 1, "cumx"] + dsn2[i, "xhat"]
}
[[alternative HTML version deleted]]
2019 Feb 01
0
nlminb with constraints failing on some platforms
>>>>> Kasper Kristensen via R-devel
>>>>> on Mon, 28 Jan 2019 08:56:39 +0000 writes:
> I've noticed unstable behavior of nlminb on some Linux
> systems. The problem can be reproduced by compiling
> R-3.5.2 using gcc-8.2 and running the following snippet:
> f <- function(x) sum( log(diff(x)^2+.01) + (x[1]-1)^2 )
> opt
2019 Jan 31
1
nlminb with constraints failing on some platforms
Prof Nash, Prof Galanos
Is it possible to use a generic code stub in front of packages that use
optimx to improve optimx use or curtail it according to the requirements?
Best Regards
Amit
+91 7899381263
________________________________________________________________________
Please request Skype as available
5th Year FPM (Ph.D.) in Finance and Accounting Area
Indian Institute
2019 Feb 04
2
nlminb with constraints failing on some platforms
I get the failure message. To be specific:
adcomp.git>R CMD BATCH --quiet test_nlminb.R
adcomp.git>cat test_nlminb.Rout
> f <- function(x) sum( log(diff(x)^2+.01) + (x[1]-1)^2 )
> opt <- nlminb(rep(0, 10), f, lower=-1, upper=3)
> xhat <- rep(1, 10)
> abs( opt$objective - f(xhat) ) < 1e-4? ## Must be TRUE
[1] FALSE
My system is described by:
adcomp.git>uname
2019 Feb 06
0
nlminb with constraints failing on some platforms
Thank you, Brad (and others),
>>>>> Brad Bell on Mon, 4 Feb 2019 07:21:18 -0700 writes:
> I get the failure message. To be specific:
adcomp.git> R CMD BATCH --quiet test_nlminb.R
adcomp.git> cat test_nlminb.Rout
>> f <- function(x) sum( log(diff(x)^2+.01) + (x[1]-1)^2 )
>> opt <- nlminb(rep(0, 10), f, lower=-1, upper=3)
>>
2019 Jan 31
0
nlminb with constraints failing on some platforms
This is not about the failure on some platforms, which is an important
issue. However, what is below may provide a temporary workaround until
the source of the problem is uncovered.
FWIW, the problem seems fairly straightforward for most optimizers at my
disposal in the R-forge (developmental) version of the optimx package at
https://r-forge.r-project.org/projects/optimizer/
I used the code
##
2007 Feb 17
1
Solve in maximum likelihood estimation
Hi,
I got the following problem.
I am doing a maximum likelihood estimation for a Kalman Filter.
For this purpose, I have to invert an error matrix Ffast of dimension
"no. parameters X no.parameters". The usualy optim methods often find only
local minima, so I decided to make the optimization using the SANN
algorithm, which is very slow already.
However, this becomes a real problem
2007 Oct 23
1
Compute R2 and Q2 in PLS with pls.pcr package
Dear list
I am using the mvr function of the package pls.pcr to compute PLS
resgression using a X matrix of gene expression variables and a Y matrix
of medical varaibles.
I would like to obtain the R2 (sum of squares captured by the model) and
Q2 (proportion of total sum of squares captured in leave-one-out cross
validation) of the model.
I am not sure if there are specific slots in the
2002 Apr 24
3
nonlinear least squares, multiresponse
I'm trying to fit a model to solve a biological problem.
There are multiple independent variables, and also there are multiple
responses.
Each response is a function of all the independent variables, plus a set of
parameters. All the responses depend on the same variables and parameters -
just the form of the function changes to define each seperate response.
Any ideas how I can fit
2013 Feb 05
1
R -HELP REQUEST
Good morning to you all,
Sorry for taking your time from your research and
teaching schedules.
If you have a non-stationary univariate time Series
data that has the transformation:
Say; l.dat<-log (series)
d.ldat<-diff (l.dat, differences=1)
and you fit say arima model.
predit.arima<-predict (fit.series, n.ahead=10,
xregnew= (n+1) :( n+10))
How could I re-transform
2017 Feb 15
5
paquete Rcmdr y BiodiversityR
Estimados,
Muchas gracias por sua ayuda, ya pude instalar data.table y esta funcionando.
Respecto al paquete biodiversityR, no se porque ahora no me corre. El script esta correcto, pero no se porque me tira error.
> fase<-diversitycomp(biobsp, y=biopcat,factor1="Fase",index="richness",method=?s")
Error in diversitycomp(biobsp, y = biopcat, factor1 =