Is it possible to defragment a datafile ??

I've a datafile of 5 GB.. I checked dba_segments and found that it has only 880 MB occupied in that datafile .
When i tried to resize the datafile to 1 GB , it throws an error "ORA-03297: file contains used data beyond requested RESIZE value"

Can anybody tell me how can i reduce this datafile size.

Regards
Saravana Kumar