Edge detection and area measurement
Here's my suggestion:


Convert the image to grayscale
Define a threshold and binarize image (only black and white)
To remove the stem apply an erode operator (the size will depend on your image)


Function syntax: https://www.mathworks.com/help/images/ref/imerode.html


apply a dilation operator (same size as in previous step)


Function "imopen" combines both steps: https://www.mathworks.com/help/images/ref/imopen.html


Sum all over the columns (considering that leaf pixels have value 1 and if you are using Matlab colsum=sum(a) )
Sum the previous vector and you will have the area ( area=sum(colsum) )