i may be wrong, but i think i read a couple of times that you can do this in an rjs file:
page << "js_obj.showTabByIndex(3)"
i think you can "feed" any JavaScript code into the page object like this, and it wll be sent back to the browser. could be wrong though, give it a try.