figure an matrix by image

1 次查看(过去 30 天)
Hellow, i have reconstruct an image of 16x16 pixels and all the pixels are in a vector of 256 elements P(256) , is it necessary to change P to a dimension P(16,16) to show it in an image. I thought it would but i tried it and it gives a error. Hope for a positive answer :)

采纳的回答

Walter Roberson
Walter Roberson 2011-5-9
image(reshape(P,16,16))
What error are you getting?
  10 个评论
Matt Fig
Matt Fig 2011-5-22
Exactly as I thought... Good enough!
Walter Roberson
Walter Roberson 2011-5-22
Note that 512 does not have an integer square root. Fiboehh, what do you want to have happen if 512 is selected?

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Resizing and Reshaping Matrices 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by