367 questions
- Bountied 0
- Unanswered
- Frequent
- Score
- Trending
- Week
- Month
- Unanswered (my tags)
2
votes
1
answer
90
views
issue in MLE of New Generalized Poisson lindley Distribution
I am working with the New Generalized Poisson Lindley (NGPL) distribution, which is a two-parameter discrete distribution defined by parameters α (alpha) and β (beta).
I wrote an R function to ...
3
votes
0
answers
82
views
R Optimization Issue: Accurate Estimates for alpha1, alpha2, theta but beta1 and beta2 Estimates are Incorrect [closed]
I’m estimating parameters for the Lindley (BGPL) distribution with five parameters: alpha1, beta1, alpha2, beta2, and theta, using optim() in R for MLE. However, the MLE results are not accurate—...
0
votes
1
answer
72
views
How do I resolve 'Error in optim: non-finite finite-difference value [1]' in this example?
Running the MWE...
library(SuppDists)
library(stats4)
mle(function(x) -log(dPearson(x, N=21, rho=0.999)), 0.5)
produces an error
Error in optim(start, f, method = method, hessian = TRUE, ...) :
...
0
votes
1
answer
74
views
Problems with fitting the "fitdist" distribution parameters
Good afternoon, dear colleagues. In the process of working on the project we have problems with fitting the parameters of the distribution law using the maximum likelihood method. Please help me to ...
0
votes
1
answer
94
views
Q and R diverge in MLE-based adaptive Kalman filter
I'm implementing an adaptive Kalman filter using Maximum Likelihood Estimation (MLE) to update the process noise covariance matrix Q and measurement noise covariance matrix R. The formulas for ...
2
votes
0
answers
182
views
Modelling extreme rainfall using the Maximum Entropy method in R
I have a dataset with daily rainfall dataset from a meteorological station during the period of 2006 through 2021. The data is stored in a CSV file (here).
A demonstration of how it looks:
After ...
0
votes
1
answer
42
views
How do i make the parameter estimates positive for my user-defined distribution?
I wrote r code for my user-defined distribution. This is the r code.
x<-c(36.8, 47.2, 35.6, 36.7, 55.8, 58.7, 42.3, 37.8, 55.4, 45.2, 31.8, 48.3, 45.3, 48.5, 52.8, 45.4, 49.8, 48.2, 54.5, 50.1, 48....
2
votes
0
answers
131
views
how to run a chi-square goodness of fit test on fitting discrete probability distributions in Python
I am trying to test the fit of several probability distributions on my data and perform a Maximum Likelihood estimation and KS test on the fit of each probability distribution to my data. My code ...
1
vote
1
answer
154
views
In fitting ODE model to data by maximum likelihood estimation, why fit transformed values of the actual parameters?
I'm looking at some published R code in which the authors are fitting an ODE model to some data using maximum likelihood estimation. I don't understand why they are fitting transformed values of the ...
0
votes
2
answers
215
views
MLE() Function in R -> Error in if (!all(lower <= start & start <= upper)) { : missing value where TRUE/FALSE needed
I was trying to solve a maximum likelihood problem, but I just can't seem to get the mle() function to work. It always complains that optim() is returning non-finite values, somehow. I tried limiting ...
1
vote
1
answer
335
views
How to code in R, this log-likelihood function
An ordered logit model is given;
Consider the following log-likelihood function of the logit model:
Also given is that k = {0,1,2,3,4}, where for k = 0 & k = 4 we have alpha being -Inf and +Inf ...
3
votes
1
answer
301
views
The power law fitted curve doesn't overlap with the data points
I have been trying to fit a powerlaw to my degree distribution data using the powerlaw package by Alstott et al. Following is my code.
import networkx as nx
import powerlaw
import matplotlib.pyplot ...
0
votes
1
answer
293
views
Why does fitting a very simple ODE in the R package fitode result in an "optim" error?
I am hoping to use the R package fitode to fit a differential equation model of tumor growth. Following the fitode vignette, I built my model and attempted to fit its parameters, but instead I ...
1
vote
1
answer
49
views
how do I use analytical form as gradient with ! function?
I am trying to do MLE (Maximum Likelihood Estimation) with analytical derivatives using Optim.
The tutorial of Optim.jl says that we can make ! function as follows
function g!(G, x)
G[1] = -2.0 * (1.0 ...
0
votes
1
answer
116
views
Error in EM algorithm: Non-finite Function Value in Likelihood Estimation with Integrals
I am encountering a persistent issue in my R program while performing Monte Carlo simulations for Maximum Likelihood Estimation (MLE). The simulation involves drawing samples from a modified Weibull ...