Borrar filtros
Borrar filtros

Is it possible to disable plot/figure generation in an entire script?

43 visualizaciones (últimos 30 días)
This is more of a trivial request, but it would be convenient for me if there was a setting I could change before running a script that simply squelches all figure and plot creation.
Does anyone know if this type of thing exists?
  1 comentario
gilles miet
gilles miet el 7 de Dic. de 2018
Hi, In case you know which display functions are called, simply overload them by defing new dummy functions with same name and varargin.
e.g. for plot function:
Create a plot.m in current directory or in any custom path directory as follows:
function plot(varargin)
disp('doing nothing');
Ignore matlab warnings telling you you overload a Matlab built-in function (you are doing it on purpose)
When plot is called you get:
>> x=randn(1,10);
>> plot(x)
doing nothing

Iniciar sesión para comentar.

Respuesta aceptada

Doug Hull
Doug Hull el 27 de Oct. de 2014
A sneaky way of kind of sort of doing this is:
To undo this:
It means the new figures will be visible off. It kind of does what you are looking for, kind of.
  6 comentarios

Iniciar sesión para comentar.

Más respuestas (0)


Más información sobre Graphics Objects 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