How to update a figure while running Octave in terminal

View: New views
2 Messages — Rating Filter:   Alert me  

How to update a figure while running Octave in terminal

by AlexRSS :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Amazingly ignorant question... I'm running Octave using the terminal in OSX.  I have a function that initializes a figure, then calls another function that imagesc's a matrix in that figure.  On every iteration of the function a new matrix should be printed to the figure.  Presently the figure only updates after the entire function has run.  The figure should update continuously while the function is running.  How can I get a figure to update continuously during a function run while running Octave in the terminal?

Thanks!

Alex

Re: How to update a figure while running Octave in terminal

by roumba :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Have you tried adding the command drawnow after the plot command that updates the plot?


AlexRSS wrote:
Amazingly ignorant question... I'm running Octave using the terminal in OSX.  I have a function that initializes a figure, then calls another function that imagesc's a matrix in that figure.  On every iteration of the function a new matrix should be printed to the figure.  Presently the figure only updates after the entire function has run.  The figure should update continuously while the function is running.  How can I get a figure to update continuously during a function run while running Octave in the terminal?

Thanks!

Alex