0

I have RGB brightness values over a possible range of 1-255. I am already computing Coefficient of Variation, but since my domain is strictly limited, I am interested in seeing a measure of how spread out a given channel's values are over the domain.

I am considering getting Std Dev over 254 or possibly p-range over 254. (You may detect I am weak in statistics.) Is there any standard measurement for this kind of situation, and what is it called?

Sycorax
  • 76,417
  • 20
  • 189
  • 313
philologon
  • 133
  • 7
  • 1
    Standard deviation makes no assumptions about range of the variable. – Tim Apr 19 '19 at 15:14
  • 1
    What are you going to use this statistic for? – Peter Flom Apr 19 '19 at 15:15
  • I am seeking patterns in aerial imagery develop algorithms to brighten pixels in shadows to be of similar brightness as their near neighbor pixels in direct sunlight. Also, many areas in shadow have similar means with still water in direct sunlight, so I want to see if there is a way to separate those. I am in an early phase of this work, seeking approaches that can discriminate among types. – philologon Apr 19 '19 at 15:21
  • Depending on your needs, the standard deviation may be more useful than the coefficient of variation. I would think in this case that the absolute differences are more interesting than the relative differences. You may also be interested in a transformation like $y = \frac{x}{(x+0.5)(255.5-x)}$ to stretch the range endpoints. You may also want to take a look at the [InterQuartile Range](https://en.wikipedia.org/wiki/Interquartile_range). [Edited comment.] – Ertxiem - reinstate Monica Apr 19 '19 at 15:25
  • Just a small detail: if it's an RGB colour code, then the minimum is $0$ unless you have some type of restriction. And, by the way, you can use [MathJax](https://math.meta.stackexchange.com/questions/5020/) to write the range as $[0; 255]$. – Ertxiem - reinstate Monica Apr 19 '19 at 15:25
  • @Tim I understand the equation for Standard Deviation does not consider domain range. But there is a relation. If I have a domain range of 1-255, then this limits the possible value of Standard Deviation. Similar to how Standard Deviation makes no assumptions about the mean, but people still compute Coefficient of Variation on occasion. – philologon Apr 19 '19 at 15:26
  • The problem with the coefficient of variation is that darker areas would tend to have larger coefficient of variation than brighter areas. I'm not sure if that is intended. On the other end of the brightness range, overexposed images would have larger values of the brightness and small coefficient of variation. – Ertxiem - reinstate Monica Apr 19 '19 at 15:28
  • Thank you @Ertxiem. When I brighten the shadows, I will be performing some kind of stretch. But at my current (early) stage, I want to see how focused the values are around the mean. Also, for now I have lost my 0-values to NoData. I will correct this mistake in my process later, but there will be very few 0-values in aerial and satellite imagery. – philologon Apr 19 '19 at 15:30
  • @Ertxiem, yes. This is why I want to divide by domain range instead of mean. – philologon Apr 19 '19 at 15:31

1 Answers1

0

Maybe you can consider calculating entropy. It is a better tool for representing the variation of binned data like a RGB image.

Monotros
  • 742
  • 4
  • 10
  • Thank you. I did not know about this. (For my own reference, https://stats.stackexchange.com/questions/235270/entropy-of-an-image) – philologon Apr 19 '19 at 23:01