> I want to call that script from within an HTML document.  How would I do
> so?  Within the HTML document, would I just treat it the same way I call
> external javascript:

The call to a script embedded or linked to an HTML document would have
to be performed by some software reading the HTML. That software could
be on the client side (like a browser) or on the server side (like an
HTTP server plugin). JavaScript usually runs in the browser, and so
<script> tags are normaly ignored by the server.

To embed Ruby in HTML, the most popular choice seems to be ERB:

http://www.ruby-doc.org/stdlib/libdoc/erb/rdoc/classes/ERB.html

That woud be interpreted on the server-side, provided your HTTP server
is properly configured.

If you want to use Ruby to generate dynamic pages, you should look
into Ruby on Rails or Camping. Those provide not only a way to embed
Ruby in HTML, but some extra functionality to build dynamc sites.

Cheers,

Luciano