Borrar filtros
Borrar filtros

How to remove the "Maximum number of function evaluations has been exceeded" prompt when generating random numbers

1 visualización (últimos 30 días)
Dear
I am trying to calculate the confidence interval of a quantity using the MC method. For that I calculate n=20000 pseudo data. When running the program Matlab continuously prompt:
Exiting: Maximum number of function evaluations has been exceeded
- increase MaxFunEvals option.
Current function value: 0.000219
This prompt is like the program gives in a optimization or root finding routines and I do not understand the reason of this in a random number generator. Is there any way to supress this?
Thanks in advance

Respuestas (1)

Walter Roberson
Walter Roberson el 11 de Dic. de 2017
Yes. You can use lastwarn to find the identifier of the warning and you can use warning() to turn it off.
However it would probably make more sense to debug the code to figure out which function is generating the message, and then to pass an options structure to the function to permit it to take more steps.

Categorías

Más información sobre Creating and Concatenating Matrices en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by