how to make 10 by 10 matrix into 1 by 100?
2 次查看(过去 30 天)
显示 更早的评论
for example i am extracting LBP of 10 images of size 100 by 100. LBP function returns feature vector size 100 by 100 . to store each fv of each image class consuming 100 rows and 100 columns,
i want to store each fv belonging to their respective class in one long row forming 100*100= 10,000 rows for each image class.
similarly i obtain fv 10 by 10,000 for 10 images.
how can i do that?
0 个评论
采纳的回答
Star Strider
2016-12-9
It depends on how you want the vector to be formatted.
The easiest way is:
fvv = fv(:);
where ‘fv’ is your original (100 x 100) matrix, and ‘fvv’ is a (10^4 x 1) vector. It is created as:
fvv = [fv(:,1); fv(:,2); ...; fv(:,100)];
0 个评论
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!