Func thar operates like repmat
1 次查看(过去 30 天)
显示 更早的评论
Hi i need to write in one code line function who does the same as repmat function Anyone's idea please :)
0 个评论
采纳的回答
Walter Roberson
2017-7-30
Hint:
Instead of writing
MyRGBImage = repmat(MyGrayScaleImage, 1, 1, 3)
I write
MyRGBImage = repmat(MyGrayScaleImage(:,:, ones(1,3))
2 个评论
Walter Roberson
2017-7-31
Sorry, I meant to write,
MyRGBImage = MyGrayScaleImage(:,:, ones(1,3))
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!