 
 
 scraperwiki.alert = (title, message, level=0) ->
-  # [title] and [message] should be html strings. The first is displayed in bold.
-  # If [level] is a truthful value, the alert is printed in red.
+  ###
+  [title] and [message] should be html strings. The first is displayed in bold.
+  If [level] is a truthful value, the alert is printed in red.
+  ###
   $a = $('<div>').addClass('alert').prependTo('body')
   $a.addClass('alert-error') if level
   $a.html """<button type="button" class="close" data-dismiss="alert">&times;</button> <strong>#{title}</strong> #{message}"""
 
 
 scraperwiki.readSettings = ->
-  # returns dataset and tool settings from the current tool's URL hash
+  ###
+  Returns dataset and tool settings from the current tool's URL hash
+  ###
   return null if window.location.hash is ''
   hash = window.location.hash.substr(1)
   try



scraperwiki.dataset.sql.meta = (success, error) ->
  # get info about the main dataset's SQL database.
  # [success] and [error] callbacks are optional,
  # since this returns a jQuery deferred object on which
  # you can chain .done() and .fail() handlers.
  settings = scraperwiki.readSettings()
  boxSettings = settings.target ? settings.source
  options =



scraperwiki.dataset.sql = (sql, success, error) ->
  ###
  Execute a SQL query on the main dataset.
  [success] and [error] callbacks are optional,
  since this returns a jQuery deferred object on which
  you can chain .done() and .fail() handlers.
  ###
  settings = scraperwiki.readSettings()
  boxSettings = settings.target ? settings.source
  options =
