I believe the very small size of your image is messing with the heuristics of the "edge" function to find thresholds. You can either define thresholds manually like:
edge_s = edge(im2,'sobel',0.1);
or resize your image before the operation:
im2 = resize(im2,5,'nearest');