Yahoo chat has it, AIM has it and most other common internet messenger softwares has it, i am referring to the invisible mode available on these application.
GTalk as of now does not have an invisible mode option, however in an recent update to Gmail they have added this feature to GMail chat. But it won’t work if you are logged in simultaneously with Google Talk. So now you can be offline but also chat with friends who are online, completely invisible.
Also setting up your invisible mode in Gmail chat is also very simple, refer the adjoining image here, use the invisible option now available under the 'set status here' option.
Google Talk does not allow users to decide when their status changes to 'idle' and back. The result is that others can easily know whether or not you're at your computer. however there are some free softwares that can assist you to take control of your GTalk status.
Try gAlwaysIdle, it adds two new options to Google Talk, allowing you to change your status to be 'always idle' or 'never idle'. When your status is set to 'always idle', you'll appear idle to your Google Talk buddies, even if you're sitting at your computer typing e-mails and sending IMs. The software is freely available here..