How to get the histogram features of an RGB image? and can use it as color extraction? i want to find the mean, variance ,skewness, energy ,kurtosis, and entropy .. please help

조회 수: 1 (최근 30일)
I have this project that need to extact the color features . I already know how to get the average RGB but i want to add more feautes .

채택된 답변

Niti K
Niti K 2019년 2월 26일
you can either convert rgb image to grayscale using rgb2gray or plot histograms for individual channel using indexing.
for example red channel for an RGB image can be accessed by I(:,:,1) where I is the rgb image.
  댓글 수: 5
Bjorn Gustavsson
Bjorn Gustavsson 2019년 2월 27일
For colour extraction you could first convert the image from RGB to HSV, HSI (though that has wrapping/branch-cut issues in the hue) or Lab space. Those image formats might give more meaningful colour histograms. Also have a look at the file exchange contributions that does this task well:

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

추가 답변 (1개)

Image Analyst
Image Analyst 2019년 2월 28일
Not sure you really need all those, but for what it's worth, attached is my code for finding central spatial moments of an image.

카테고리

Help CenterFile Exchange에서 Histograms에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by