Hello, All
I am using the following code to create a dataset:
my_dataset=cell(5,1); my_dataset=cell2dataset([{'Variable_1'};my_dataset]); my_dataset.Variable_1=repmat('some_string',5,1);
However, the result is weird: instead of a continuous text string, it is a combination of individual characters (shown below)
'''s''' '''o''' '''m''' '''e''' '''_''' '''s''' '''t''' '''r''' '''i''' '''n''' '''g''' '''s''' '''o''' '''m''' '''e''' '''_''' '''s''' '''t''' '''r''' '''i''' '''n''' '''g''' '''s''' '''o''' '''m''' '''e''' '''_''' '''s''' '''t''' '''r''' '''i''' '''n''' '''g''' '''s''' '''o''' '''m''' '''e''' '''_''' '''s''' '''t''' '''r''' '''i''' '''n''' '''g''' '''s''' '''o''' '''m''' '''e''' '''_''' '''s''' '''t''' '''r''' '''i''' '''n''' '''g'''
The result I am looking for should be like following:
some_stringsome_stringsome_stringsome_stringsome_string
How should I change my code to get the correct result? Thanks!
Best Answer