What does ~ stand for in the following example?

3 次查看(过去 30 天)
What does this piece of code mean? [~,~,P] = size(I);

采纳的回答

Star Strider
Star Strider 2016-1-1
The ‘~’ in that context tells the function to not return that particular output. Apparently ‘I’ is a 3D array, and the person who wrote that only wanted to know the number of ‘pages’ (3rd dimension) of it, not the number of rows or columns, the first and second dimensions respectively.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Get Started with MATLAB 的更多信息

标签

Community Treasure Hunt

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

Start Hunting!

Translated by