It seems to me only Yoda and Obi-wan do this. I seem to remember seeing a lot of dead Jedi bodies lying around in AOTC. Qui-Gon did not disappear either. So why Obi-wan and Yoda? The only thing I can think of is that they were both at peace in the end, well kinda. Ben looked pretty calm when he let Vader cut him in half. He had accepted what had to be done. Yoda knew it was time for him to die. He had done all he could for Luke.
They only thing is, Anakin should have disappered as well. He managed to save his son and turn back to the light. The only thing I can think of is that his body had been twisted by the Dark Side so it could not be accepted into the force the way Yoda's or Obi-wan's was. That was the reason he could never wield Sith Lighting as Darth Vader, he was damaged goods.