How can I perform Proportional Stratified Random Sampling of the raster with 5 different classes in R software? I tried 'simple Stratified' function, but the output was not proportional because the classes are not of an equal size?
Do you want proportional allocation, or optimal allocation? Neyman allocation? Is this continuous data? You need to know something about variance of perhaps a preliminary sample, with regard to the strata, for optimal stratification.
You could try a textbook such as
Cochran, W.G.(1977), Sampling Techniques, 3rd ed., John Wiley & Sons.
or
Lohr, S.L.(2010), Sampling: Design and Analysis, 2nd ed., Brooks/Cole.
Those should have sections that will address your project, I think, but I have never dealt with raster data, and there may be some special considerations.
Sorry. Don't know about R, but I did see a comprehensive looking manual on an Internet search recently.
This is a bit late to the game but, I just had to do this. I will be formalizing this approach in the spatialEco package. Previous answers did not address a proportional (adaptive) sample size per strata in the raster so, here is a way to do exactly that. Please note that I am moving code bases away from the raster package to the replacement terra package.