I want to analyze some images (nearly 1000) in a loop. I want to analyze HSV and RGB. I have masked those images in ImageJ, which is binary masked. I tried to explore them in R, but all the results came as NA. I also checked those images (some of them) separately in R to determine whether they were correctly masked, and the result was in matrix 0,0,0 1,1,1. But still, the result is NA. I used a chatbot to generate and analyze code. Can anyone suggest any codes and packages?