how print multiple values on screen in one line in matlab
5 次查看(过去 30 天)
显示 更早的评论
I am doing image image processing in matlab , so if many object will be detected at once, then i want multiple vallues in at once in one line . I mean I will be getting cordinates of every box which is detected .
0 个评论
回答(2 个)
Xiaotao
2024-6-5
The function you need is fprintf.
An example,
A = magic(3)
B = magic(5);
fprintf("%d, ", A, B)
0 个评论
Yukthi S
2024-6-5
编辑:Yukthi S
2024-6-5
Hi Gauri,
I understand that you wanted to print multiple coordinates of the bounding boxes detected, in one line. If you are dealing with string datatype, you can use “join” function available in MATLAB for string concatenation, refer to the following documentation link for more information: https://www.mathworks.com/help/releases/R2023b/matlab/ref/join.html?s_tid=doc_ta
But if you want to concatenate numeric values, use “horzcat” or “vertcat” functions available in MATLAB. You can find more information in the below links:
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Matrix Indexing 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!