Borrar filtros
Borrar filtros

display colored output in command window

2 visualizaciones (últimos 30 días)
Sivakumaran Chandrasekaran
Sivakumaran Chandrasekaran el 27 de Mzo. de 2012
Editada: DGM el 19 de Jun. de 2024
Can the numbers be displayed in command window in some colors. I mean ... 1 should be displayed in red color and 2 should be displayed in blue color.
Regards, Siva
Edit [27 Mar 2012, 08:25 BST - OK] Erased email address.

Respuestas (1)

Oleg Komarov
Oleg Komarov el 27 de Mzo. de 2012
You can use this submission from the FEX: cprintf
Edit
An example with cprintf:
A = [5 6; 9 10];
cprintf('cyan' , '%3.0f' ,A(1));
cprintf('Magenta' , '%3.0f \n',A(3));
cprintf('blue' , '%3.0f' ,A(2));
cprintf('green' , '%3.0f \n',A(4));
  3 comentarios
Oleg Komarov
Oleg Komarov el 27 de Mzo. de 2012
It's a submission of the FEX. Follow the link.
Sivakumaran Chandrasekaran
Sivakumaran Chandrasekaran el 28 de Mzo. de 2012
Editada: DGM el 19 de Jun. de 2024
Hi,
I checked the link. Thanks for your help.
Regards, Siva

Iniciar sesión para comentar.

Categorías

Más información sobre Environment and Settings 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