It is possible, and can be worth it.
IF, and it's a big IF, you like all of the parts you have AND, and that's a big AND, there's no compatability issues then you can find some great frames to upgrade to.
However, you can get into issues with compatability, like rear hub width, headset sizing, seatpost sizing, brake type, etc...and all of these can be very costly issues to resolve that might warrant choosing a new bike instead.
My suggestion would be to figure out what you have and what it would work with.