What does sc in imagesc stand for?

조회 수: 4 (최근 30일)
David Katz
David Katz 2023년 3월 26일
답변: Image Analyst 2023년 3월 27일
Pretty much the title question. Thank you.

답변 (2개)

the cyclist
the cyclist 2023년 3월 26일
편집: the cyclist 2023년 3월 26일
scaled colors
doc imagesc
  댓글 수: 8
DGM
DGM 2023년 3월 27일
편집: DGM 2023년 3월 27일
Does it really matter whether those two letters mean "scaled" or "scaled color" or "scaled cdata"?
Or is it more important what all three of those names suggest? All three describe the behavior of the function -- specifically how it differs from the behavior of image(). Imagesc() is basically a simple wrapper for image() which adds the convenience of setting the 'CDataMapping' property to 'scaled'. It offers a few related conveniences, but that's the main one that most people would use when calling it with no extra arguments. Doing this:
imagesc(myimage)
is (basically) the same as
image(myimage,'cdatamapping','scaled') % default is 'direct'
I don't know if that was even part of the curiosity, but I'll just throw that out there anyway.
I will add one thought. Imagesc() really looks like the type of thing you'd write after you found yourself doing something simple way too often. So if you're going to write a simple convenience tool, what's the likelihood the name you'd use is in some way an abbreviated reference to the options you want to avoid typing again?
I could be wrong. I don't know what the earliest versions of these two functions looked like.
Walter Roberson
Walter Roberson 2023년 3월 27일
By the way,
edit imagesc

댓글을 달려면 로그인하십시오.


Image Analyst
Image Analyst 2023년 3월 27일
Well I always thought it meant scaled since it works for gray scale and I don't use the word "color" for gray levels. And it is consistent with the sc in soundsc() vs sound() function where it means scaled (since sounds don't have visible colors).
However the help says this:
imagesc
Display image with scaled colors
imagesc(C) displays the data in array C as an image that uses the full range of colors in the colormap. Each element of C specifies the color for one pixel of the image.
So I guess it's somewhat ambiguous whether the c is from "scaled", or if it's from "colors".

카테고리

Help CenterFile Exchange에서 Startup and Shutdown에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by