#NEWLINE# @ add_source_code_and_doc #NEWLINE# def chart_default_options( request , title , code , doc , sidebar_items ) : #NEWLINE# #INDENT# '\n    Some default options explained\n    -------------------------------\n    \n    Even though the ``chart_options`` are not specified, Chartit \n    automatically tries to guess the axis titles, chart titles etc.\n    \n    Points to note:\n    \n    - Notice how the axes are named, chart is named etc. by default.\n    ' #NEWLINE# ds = DataPool ( series = [ { #NEWLINE# #INDENT# 'options' : { #NEWLINE# #INDENT# 'source' : MonthlyWeatherByCity . objects . all ( ) , #NEWLINE# #UNINDENT# } , #NEWLINE# 'terms' : [ 'month' , 'houston_temp' , 'boston_temp' ] , #NEWLINE# #UNINDENT# } , { #NEWLINE# #INDENT# 'options' : { #NEWLINE# #INDENT# 'source' : MonthlyWeatherSeattle . objects . all ( ) , #NEWLINE# #UNINDENT# } , #NEWLINE# 'terms' : [ { #NEWLINE# #INDENT# 'month_seattle' : 'month' , #NEWLINE# #UNINDENT# } , 'seattle_temp' ] , #NEWLINE# #UNINDENT# } ] ) #NEWLINE# cht = Chart ( datasource = ds , series_options = [ { #NEWLINE# #INDENT# 'options' : { #NEWLINE# #INDENT# 'type' : 'line' , #NEWLINE# 'stacking' : False , #NEWLINE# #UNINDENT# } , #NEWLINE# 'terms' : { #NEWLINE# #INDENT# 'month' : [ 'boston_temp' , 'houston_temp' ] , #NEWLINE# 'month_seattle' : [ 'seattle_temp' ] , #NEWLINE# #UNINDENT# } , #NEWLINE# #UNINDENT# } ] ) #NEWLINE# return render_to_response ( 'chart_code.html' , { #NEWLINE# #INDENT# 'chart_list' : cht , #NEWLINE# 'code' : code , #NEWLINE# 'title' : doc , #NEWLINE# 'doc' : doc , #NEWLINE# 'sidebar_items' : sidebar_items , #NEWLINE# #UNINDENT# } )