Looking for help with labelling groups
Hey everyone,
so far I’ve read all Matlab entrys on adding/creating categories and/or labels but I haven’t found something fitting that works for me. I have a set of data in 178×13 double format, the variable names in a 1×13 cell format and the group classification in a 178×1 double, which ist just 1 2 and 3. In different projects I had a 178×1 cell instead containing the names of the groups and I would use that to generate a double using findgroups. However, now I would like to do the reverse action and generate a 178×1 cell value with the names instead of numbers. Num2Cell does not work here of course because I would like to tell Matlab to put "GroupA" for every 1 in the group classification 178×1 double and "GroupB" for every 2 and GroupC for every 3. I have information that the first 59 belog to GroupA etc, but I don’t know how to implement that either. Maybe it’s the language barrier but I really don’t even know what to search for anymore. Any help is much appreciated!Hey everyone,
so far I’ve read all Matlab entrys on adding/creating categories and/or labels but I haven’t found something fitting that works for me. I have a set of data in 178×13 double format, the variable names in a 1×13 cell format and the group classification in a 178×1 double, which ist just 1 2 and 3. In different projects I had a 178×1 cell instead containing the names of the groups and I would use that to generate a double using findgroups. However, now I would like to do the reverse action and generate a 178×1 cell value with the names instead of numbers. Num2Cell does not work here of course because I would like to tell Matlab to put "GroupA" for every 1 in the group classification 178×1 double and "GroupB" for every 2 and GroupC for every 3. I have information that the first 59 belog to GroupA etc, but I don’t know how to implement that either. Maybe it’s the language barrier but I really don’t even know what to search for anymore. Any help is much appreciated! Hey everyone,
so far I’ve read all Matlab entrys on adding/creating categories and/or labels but I haven’t found something fitting that works for me. I have a set of data in 178×13 double format, the variable names in a 1×13 cell format and the group classification in a 178×1 double, which ist just 1 2 and 3. In different projects I had a 178×1 cell instead containing the names of the groups and I would use that to generate a double using findgroups. However, now I would like to do the reverse action and generate a 178×1 cell value with the names instead of numbers. Num2Cell does not work here of course because I would like to tell Matlab to put "GroupA" for every 1 in the group classification 178×1 double and "GroupB" for every 2 and GroupC for every 3. I have information that the first 59 belog to GroupA etc, but I don’t know how to implement that either. Maybe it’s the language barrier but I really don’t even know what to search for anymore. Any help is much appreciated! groups, classes, label MATLAB Answers — New Questions