Why can't I instanciate, create, construct class objects via cellfun?
4 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Roland
el 8 de Abr. de 2014
Comentada: Roland
el 9 de Abr. de 2014
This is an example class file:
classdef tmp < handle
properties
str
end
methods
function self = tmp(str)
self.str = str;
end
end
end
Then
cellfun(@tmp,{'a','b'})
produces the error:
Error using cellfun
tmp output type is not currently implemented.
0 comentarios
Respuesta aceptada
Walter Roberson
el 8 de Abr. de 2014
Use 'uniform', 0 for cellfun. If you need to convert to a matrix afterwards you can cell2mat()
Más respuestas (0)
Ver también
Categorías
Más información sobre Assembly 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!