lib/annotated_timeline.rb
#this version will automatically create a div inline for you. 
#note that if it is in the middle of the page, the javascript will try to execute before the page load completes
this version will automatically create a div inline for you.
note that if it is in the middle of the page, the javascript will try to execute before the page load completes
this version will automatically create a div inline for you . note that if it is in the middle of the page the javascript will try to execute before the page load completes
def inline_annotated_timeline(daily_counts_by_type, width = 750, height = 300, div_id_to_create = 'graph', options = {})
    html = "<script type=\"text/javascript\" src=\"http://www.google.com/jsapi\"></script>"
    html << annotated_timeline(daily_counts_by_type, div_id_to_create, options)
    html << "<div id=\"#{div_id_to_create}\" style=\"width: #{width}px\; height: #{height}px\;\"></div>"    
  end
def inline_annotated_timeline ( daily_counts_by_type , width = 750 , height = 300 , div_id_to_create = 'graph' , options = { } ) html = "<script type=\"text/javascript\" src=\"http://www.google.com/jsapi\"></script>" html << annotated_timeline ( daily_counts_by_type , div_id_to_create , options ) html << "<div id=\"#{div_id_to_create}\" style=\"width: #{width}px\; height: #{height}px\;\"></div>" end
this version will automatically create a div inline for you.
this version will automatically create a div inline for you .
daily_counts_by_type
<not_specific>
width
<not_specific>
height
<not_specific>
div_id_to_create
<not_specific>
options
<not_specific>