This is a bit of a necro, but I think it is relevant because when searching google for "usb drive unplugged mac lost files" it comes up as one of the top results (unfortunately).
I have a portable hard drive that has lost files repeatedly due to me being a windows user that is accustomed to yanking the drive when not copying and then migrating over to the mac.
The corruption could have nothing to do with your most recent files. I had files that were on my drive and copied safely months ago, then yanking the drive when no relevant apps or files were in use caused the files to disappear.
This has happened to me twice, and both times I didn't notice the issue until much later because the removed files were essentially archived, until I went to dig through the archives and noticed them gone.
Using "disk utility" to repair the drive makes found.000 and dir0000.chk type files/directories, and I could recover SOME of the files this way, that show up as orphaned files.
I have found that other "disk recovery utilities" generally don't help with the yanked usb problem. Of course, I've only had these 2 instances where I tried to do this, and any time it happens I'd try them again if a disk utility fix doesn't work.
To other folks with these problems, a lot in this thread is flat out BS.
In theory it is OK to yank a drive if you are 100% sure it is not in use at all or will not need to be in use later due to some delayed system function. From a computer science point of view this is obvious.
However, is clear to me that windows works differently than osx does in its file structure. I'm not going to throw around expertise that I don't have, just the experience that yanking my drive has caused files to poof on OSX where it has not happened to me for a few versions of windows now. I even try to eject the drives in windows, but 90% of the time I get the message that it is unable to be ejected. So I yank it, and nothing has gone wrong to date.
OSX simply does not work that way (by default at least). I have yanked drives accidentally on computers that had no file activity for days, to then see the files on the drives poof.
You can hee haw all day long about how it is safe, but you can also walk up to any default config mac and reproduce the poofing if you have a usb drive with certain data patterns on it once you experience it.