Effacer les filtres
Effacer les filtres

display newline string from cell array

6 vues (au cours des 30 derniers jours)
Elysi Cochin
Elysi Cochin le 16 Mar 2018
I have a cell array of characters. In that i have a newline character.
I use strjoin to get the full sentence
fullsentence = strjoin(word, '');
But when i display output is coming as
ER\n\nR
but i wanted it as
ER
R

Réponse acceptée

Geoff Hayes
Geoff Hayes le 16 Mar 2018
Elysi - how are you displaying the output of fullsentence? If you do
fprintf(fullsentence)
then you should see the \n evaluated as line breaks.

Plus de réponses (0)

Catégories

En savoir plus sur Characters and Strings dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by