matlab - Activate a specific figure when returning from a nested function -


i have plotting function inside imshow() command.

the plot , image should in separate figures.

at return inside function current figure of plot imshow() puts image onto same figure of plot , kills plot.

what can done make imshow() open or existing own figure, while keeping such manner of nested function calling?

well, apparently, i've found answer time done question, because find interesting enough , find nothing answering i'm writing answer well.

the algo this:

  1. open figure before imshow(nested_function());
  2. upon starting nested_function() save handle previous figure fh_prev = gcf; example
  3. do plots along nested_function()
  4. before return nested_function() activate previous figure command figure(fh_prev);

Comments

Popular posts from this blog

how to insert data php javascript mysql with multiple array session 2 -

multithreading - Exception in Application constructor -

windows - CertCreateCertificateContext returns CRYPT_E_ASN1_BADTAG / 8009310b -