<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Njiang4</id>
	<title>Expertiza_Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.expertiza.ncsu.edu/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Njiang4"/>
	<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=Special:Contributions/Njiang4"/>
	<updated>2026-05-11T17:26:22Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.41.0</generator>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97101</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97101"/>
		<updated>2015-05-05T01:41:50Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Project Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Project Description=&lt;br /&gt;
The goal of this project is to present the the data in Expertiza in a more convenient way. Through the use of charts and graphs to enhance certain pages, such as the student's scores page and the instructor's scores page, and allow for the users to get an at-a-glance analysis of the data without having to dive into the tables.&lt;br /&gt;
&lt;br /&gt;
Our project video https://www.youtube.com/watch?v=26jVUAyF6TA&lt;br /&gt;
==Purpose==&lt;br /&gt;
The purpose of this project is to add a visualization element to some of the data collected in expertiza. The aim of this is to provide a more intuitive “at-a-glance” idea of the data, some examples would be: how a student is doing on his/her assignments, or how their work compares to that of their classmates. On a less functional angle, it also enhances the aesthetics of the pages, taking the drab tables and giving them a more appealing look.&lt;br /&gt;
&lt;br /&gt;
=Overview of Approach=&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Chart Examples====&lt;br /&gt;
=====Area Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/area_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/areachart.html#Example&lt;br /&gt;
  def area_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['2004', 1000, 400],&lt;br /&gt;
      ['2005', 1170, 460],&lt;br /&gt;
      ['2006', 660, 1120],&lt;br /&gt;
      ['2007', 1030, 540]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts   = { width: 400, height: 240, title: 'Company Performance', hAxis: {title: 'Year', titleTextStyle: {color: '#FF0000'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::AreaChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bar Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bar_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/barchart.html#Example&lt;br /&gt;
  def bar_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows(4)&lt;br /&gt;
    data_table.set_cell(0, 0, '2004')&lt;br /&gt;
    data_table.set_cell(0, 1, 1000)&lt;br /&gt;
    data_table.set_cell(0, 2, 400)&lt;br /&gt;
    data_table.set_cell(1, 0, '2005')&lt;br /&gt;
    data_table.set_cell(1, 1, 1170)&lt;br /&gt;
    data_table.set_cell(1, 2, 460)&lt;br /&gt;
    data_table.set_cell(2, 0, '2006')&lt;br /&gt;
    data_table.set_cell(2, 1, 660)&lt;br /&gt;
    data_table.set_cell(2, 2, 1120)&lt;br /&gt;
    data_table.set_cell(3, 0, '2007')&lt;br /&gt;
    data_table.set_cell(3, 1, 1030)&lt;br /&gt;
    data_table.set_cell(3, 2, 540)&lt;br /&gt;
&lt;br /&gt;
    opts   = { :width =&amp;gt; 400, :height =&amp;gt; 240, :title =&amp;gt; 'Company Performance', vAxis: {title: 'Year', titleTextStyle: {color: 'red'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BarChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bubble Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bubble_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/bubblechart.html&lt;br /&gt;
  def bubble_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'ID')&lt;br /&gt;
    data_table.new_column('number', 'Life Expectancy')&lt;br /&gt;
    data_table.new_column('number', 'Fertility Rate')&lt;br /&gt;
    data_table.new_column('string', 'Region')&lt;br /&gt;
    data_table.new_column('number', 'Population')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['CAN',    80.66,              1.67,      'North America',  33739900],&lt;br /&gt;
      ['DEU',    79.84,              1.36,      'Europe',         81902307],&lt;br /&gt;
      ['DNK',    78.6,               1.84,      'Europe',         5523095],&lt;br /&gt;
      ['EGY',    72.73,              2.78,      'Middle East',    79716203],&lt;br /&gt;
      ['GBR',    80.05,              2,         'Europe',         61801570],&lt;br /&gt;
      ['IRN',    72.49,              1.7,       'Middle East',    73137148],&lt;br /&gt;
      ['IRQ',    68.09,              4.77,      'Middle East',    31090763],&lt;br /&gt;
      ['ISR',    81.55,              2.96,      'Middle East',    7485600],&lt;br /&gt;
      ['RUS',    68.6,               1.54,      'Europe',         141850000],&lt;br /&gt;
      ['USA',    78.09,              2.05,      'North America',  307007000]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts    = {&lt;br /&gt;
      :width =&amp;gt; 800, :height =&amp;gt; 500,&lt;br /&gt;
      :title =&amp;gt; 'Correlation between life expectancy, fertility rate and population of some world countries (2010)',&lt;br /&gt;
      :hAxis =&amp;gt; { :title =&amp;gt; 'Life Expectancy' },&lt;br /&gt;
      :vAxis =&amp;gt; { :title =&amp;gt; 'Fertility Rate'  },&lt;br /&gt;
      :bubble =&amp;gt; { :textStyle =&amp;gt; { :fontSize =&amp;gt; 11 } }&lt;br /&gt;
    }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BubbleChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The resulting chart looks like below.&lt;br /&gt;
[[File:BubbleChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
pie chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.pie(:data =&amp;gt; [20, 35, 45])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Piechart.png]]&lt;br /&gt;
&lt;br /&gt;
These usages come from http://googlecharts.rubyforge.org/. If you want to see more usages, go and visit this site.&lt;br /&gt;
&lt;br /&gt;
===gchartrb===&lt;br /&gt;
gchartrb&amp;lt;ref&amp;gt;http://code.google.com/p/gchartrb/&amp;lt;/ref&amp;gt; is a Ruby wrapper around the Google chart API&amp;lt;ref&amp;gt;http://code.google.com/apis/chart/&amp;lt;/ref&amp;gt;. In our project, we use gchartrb to generate all the bar charts in the visualization. &lt;br /&gt;
&lt;br /&gt;
====installing====&lt;br /&gt;
Installing gchartrb is simple, just include the gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem 'gchartrb', :require =&amp;gt; 'google_chart'&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Examples====&lt;br /&gt;
=====Bar Chart=====&lt;br /&gt;
The following example code would generate a bar chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Bar Chart&lt;br /&gt;
    GoogleChart::BarChart.new('800x200', &amp;quot;Bar Chart&amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
      bc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5], '0000ff'&lt;br /&gt;
      bc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], 'ff0000'&lt;br /&gt;
      bc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,4,5,6], '00ff00'&lt;br /&gt;
      puts &amp;quot;\nBar Chart&amp;quot;&lt;br /&gt;
      puts bc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:BarChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
=====Line Chart=====&lt;br /&gt;
The following example code would generate a line chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Line Chart&lt;br /&gt;
    GoogleChart::LineChart.new('320x200', &amp;quot;Line Chart&amp;quot;, false) do |lc|&lt;br /&gt;
      lc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5,6], '0000ff'&lt;br /&gt;
      lc.show_legend = true&lt;br /&gt;
      lc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], '00ff00'&lt;br /&gt;
      lc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,3,2,1], 'ff0000'&lt;br /&gt;
      lc.axis :y, :range =&amp;gt; [0,6], :color =&amp;gt; 'ff00ff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.axis :x, :range =&amp;gt; [0,6], :color =&amp;gt; '00ffff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.grid :x_step =&amp;gt; 100.0/6.0, :y_step =&amp;gt; 100.0/6.0, :length_segment =&amp;gt; 1, :length_blank =&amp;gt; 0&lt;br /&gt;
      puts &amp;quot;\nLine Chart&amp;quot;&lt;br /&gt;
      puts lc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:AeraChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Circles===&lt;br /&gt;
----&lt;br /&gt;
We use the Circles lightweight JavaScript library generating circular graphs to represent the average scores expressed as percentage with animation.&lt;br /&gt;
&lt;br /&gt;
Here is an example of the circles we use.&lt;br /&gt;
[[File:Circles.png|center]]&lt;br /&gt;
&lt;br /&gt;
For more details about the circles.js, you can refer to https://github.com/lugolabs/circles&lt;br /&gt;
====Usage====&lt;br /&gt;
----&lt;br /&gt;
Include the circles.js or circles.min.js file in your HTML file. There are no dependencies.&lt;br /&gt;
&lt;br /&gt;
And create a placeholder div in your HTML:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;circle&amp;quot; id=&amp;quot;circles-1&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a graph by calling, the id should match id of the placeholder div:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
var myCircle = Circles.create({&lt;br /&gt;
  id:           'circles-1',&lt;br /&gt;
  radius:       60,&lt;br /&gt;
  value:        43,&lt;br /&gt;
  maxValue:     100,&lt;br /&gt;
  width:        10,&lt;br /&gt;
  text:         function(value){return value + '%';},&lt;br /&gt;
  colors:       ['#D3B6C6', '#4B253A'],&lt;br /&gt;
  duration: 	  400,&lt;br /&gt;
  wrpClass:	    'circles-wrp',&lt;br /&gt;
  textClass:	  'circles-text'&lt;br /&gt;
  styleWrapper: true,&lt;br /&gt;
  styleText:    true&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where&lt;br /&gt;
&lt;br /&gt;
* `id` 			    - the DOM element that will hold the graph&lt;br /&gt;
* `radius` 		    - the radius of the circles&lt;br /&gt;
* `value` 		    - init value of the circle (optional, defaults to 0)&lt;br /&gt;
* `maxValue` 	    - maximum value of the circle (optional, defaults to 100)&lt;br /&gt;
* `width` 		    - the width of the ring (optional, has value 10, if not specified)&lt;br /&gt;
* `colors` 		    - an array of colors, with the first item coloring the full circle (optional, it will be `['#EEE', '#F00']` if not specified)&lt;br /&gt;
* `duration` 	    - value in ms of animation's duration; defaults to 500; if 0 or `null` is passed, the animation will not run.&lt;br /&gt;
* `wrpClass` 	    - class name to apply on the generated element wrapping the whole circle.&lt;br /&gt;
* `textClass` 	    - class name to apply on the generated element wrapping the text content.&lt;br /&gt;
* `styleWrapper'   - whether or not to add inline styles to the wrapper element (defaults to true)&lt;br /&gt;
* `styleText`	    - whether or not to add inline styles to the text (defaults to true)&lt;br /&gt;
* `text`                  - the text to display at the center of the graph (optional, the current &amp;quot;htmlified&amp;quot; value will be shown). If `null` or an empty string, no text will be displayed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
API&lt;br /&gt;
----&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateRadius(Number radius)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `radius` (see `spec/responsive.html` for an example on how to create a responsive circle).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateWidth(Number width)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `width`&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateColors(Array colors)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Change `colors` used to draw the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Number value [, Number duration])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Set the value of the circle to `value`.&lt;br /&gt;
Animation will take `duration` ms to execute. If no `duration` is given, default duration set in constructor will be used.&lt;br /&gt;
If you don't want animation, set `duration` to 0.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Boolean force)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Force the redrawing of the circle if `force` is set to **true**. Do nothing otherwise.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getPercent()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the percentage value of the circle, based on its current value and its max value.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getMaxValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the max value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValueFromPercent(Number percentage)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the corresponding value of the circle based on its max value and given `percentage`.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.htmlifyNumber(Number number[, integerPartClass, decimalPartClass])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Visualization in Expertiza=&lt;br /&gt;
This section describes where in Expertiza we can use these visualizations to provide a better user experience. &lt;br /&gt;
The 'Review Score' view of the assignments can be enhanced using these visualization.&lt;br /&gt;
&lt;br /&gt;
We can see by the image below that currently the scores views includes only a large table. From a user experience perspective having a more prioritized view of the scores would be beneficial. Having all the data available for the user to peruse in a table is informative, but when the user wants only to get a quick idea of how they did in an assignment, it would be helpful to have some sort of visualization.&lt;br /&gt;
&lt;br /&gt;
[[File:score_view.png.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The above scoring which is in tabular form can be enhanced with charts.&lt;br /&gt;
&lt;br /&gt;
=Graphical Score Dashboard=&lt;br /&gt;
The scores page was augmented with bar graphs displaying the distributions of each column, as well as a circle icon for the average score for that column. This will allow for easily determining what the reviewers thought of the work, as well as what the range of scores given. The circle graphs with the averages provide a visual for the quality of the work in each of the categories.&lt;br /&gt;
&lt;br /&gt;
[[File:Score_chart.png]]&lt;br /&gt;
&lt;br /&gt;
==New View==&lt;br /&gt;
&lt;br /&gt;
We created a new view under the grades views, called participant_charts. This view is included as a partial in the grades/view_my_scores view. This allows us to not modify any of the existing views and keep the code modular.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Bar Charts==&lt;br /&gt;
&lt;br /&gt;
For the bar charts we constructed a method that, given the score and the type of bar chart, populates an instance variable that contains the charts. The code was included in the grades controller (grades_controller.rb file) and is shown below&lt;br /&gt;
&lt;br /&gt;
    def bar_chart(scores, type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;100x100&amp;quot;, &amp;quot; &amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
          data = scores&lt;br /&gt;
          bc.data &amp;quot;Line green&amp;quot;, data, '990000'&lt;br /&gt;
          #bc.axis :x, :positions =&amp;gt; [0, data.size], :range =&amp;gt; [0,100]&lt;br /&gt;
          bc.axis :y, :range =&amp;gt; [0, data.max] ,:positions =&amp;gt; [data.min, data.max]&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 70/(data.size+1),:bar_spacing =&amp;gt; 1, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
The width of the bars is dependent on the number of scores to show. Assignments with many reviews to show, require smaller bars. This is accomplished by tying the bar_width parameter, to the size of the data.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Circle Charts==&lt;br /&gt;
&lt;br /&gt;
For the circle charts showing the averages of the columns we used a javascript library, circle.js. By simply passing the scores to the .js code in the grades view as shown in the code below. The circle is then rendered automatically in a div block elsewhere in the view named the same as the id: tag below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;% ['review', 'metareview', 'feedback', 'teammate'].each do |type| %&amp;gt;&lt;br /&gt;
      &amp;lt;% if @pscore[type.to_sym][:scores][:avg]%&amp;gt;&lt;br /&gt;
        var myCircle = Circles.create({&lt;br /&gt;
      id:           '&amp;lt;%= &amp;quot;#{type}-circle&amp;quot; %&amp;gt;',&lt;br /&gt;
      radius:       25,&lt;br /&gt;
      value:        &amp;lt;%= @pscore[type.to_sym][:scores][:avg].to_i %&amp;gt;,&lt;br /&gt;
      maxValue:     100,&lt;br /&gt;
      width:        7,&lt;br /&gt;
      text:         '&amp;lt;%=@pscore[type.to_sym][:scores][:avg].to_i%&amp;gt;',&lt;br /&gt;
      colors:       ['#FFEB99', '#FFCC00'],&lt;br /&gt;
      duration:       700,&lt;br /&gt;
      textClass:      'circles-text'&lt;br /&gt;
    });&lt;br /&gt;
&lt;br /&gt;
==Show / Hide stats==&lt;br /&gt;
&lt;br /&gt;
The user might want to hide the stats, with that in mind we included a button to toggle the visibility of the charts. Making use of an existing function, toggleElement, we added a link above the charts table that when clicked hides/shows the charts. The code to accomplish this is shown below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;a href=&amp;quot;#&amp;quot; name='score-chartLink' onClick=&amp;quot;toggleElement('score-chart', 'stats');return false;&amp;quot;&amp;gt;hide stats&amp;lt;/a&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Reliability Metric=&lt;br /&gt;
Based on the uniformity of the review scores, we compiled a reliability metric. This metric encapsulates the level of agreement between the reviews, and should provide a quick at a glance notion of whether reviewers agree on the scoring for the particular assignment, or whether there is a high variance in the scores given. A good reliability score indicates that the grade given to the assignment by the reviewers is to be trusted, whereas a poor reliability score indicates that there was a high level of disagreement in the reviewers and the instructors should perhaps take a closer look at the participant's assignment.&lt;br /&gt;
This reliability score is computed from the standard deviation of the review scores. A standard deviation that's less than 10 will award a good reliability score. A standard deviation between 10 and 20 will award a medium reliability score, whereas a standard deviation greater than 20 will give a poor reliability score.&lt;br /&gt;
===Different Icon colors===&lt;br /&gt;
[[File:Green_icon.png]]&lt;br /&gt;
&lt;br /&gt;
The color of the three bars Icon, and the number of filled bars is representative of the reliability of the reviews.&lt;br /&gt;
Take the case of the green sample icon in the image above, the reviews mostly all agree. Whereas in the following two images, the icon is yellow and red respectively to signify increasingly worrying levels of disparity in review scores.&lt;br /&gt;
&lt;br /&gt;
[[File:Yellow_icon.png]]&lt;br /&gt;
&lt;br /&gt;
[[File:Red_icon.png]]&lt;br /&gt;
&lt;br /&gt;
A similar method to the one used for the bar charts was used. In this case, a horizontal bar chart was created, and the data was dictated by the qualitative score that was passed into the method. This score could be 'good', 'medium' or 'bad'. Based on this string argument the graph is created with the correct number of bars and the correct color.&lt;br /&gt;
&lt;br /&gt;
    def reliability_chart(score,type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;25x20&amp;quot;, &amp;quot; &amp;quot;, :horizontal, false) do |bc|&lt;br /&gt;
          if score == 'good'&lt;br /&gt;
            data = [1,1,1]&lt;br /&gt;
            color = '00ff00'&lt;br /&gt;
          elsif score == 'medium'&lt;br /&gt;
            data = [1,1]&lt;br /&gt;
            color = 'FFCC00'&lt;br /&gt;
          else&lt;br /&gt;
            data = [1]&lt;br /&gt;
            color = '990000'&lt;br /&gt;
          end&lt;br /&gt;
          bc.data &amp;quot;Reliability Symbol&amp;quot;, data, color&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 5,:bar_spacing =&amp;gt; 10, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
      end&lt;br /&gt;
&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97100</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97100"/>
		<updated>2015-05-05T01:01:37Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Project Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Project Description=&lt;br /&gt;
The goal of this project is to present the the data in Expertiza in a more convenient way. Through the use of charts and graphs to enhance certain pages, such as the student's scores page and the instructor's scores page, and allow for the users to get an at-a-glance analysis of the data without having to dive into the tables.&lt;br /&gt;
&lt;br /&gt;
Our project video http://youtu.be/26jVUAyF6TA&lt;br /&gt;
==Purpose==&lt;br /&gt;
The purpose of this project is to add a visualization element to some of the data collected in expertiza. The aim of this is to provide a more intuitive “at-a-glance” idea of the data, some examples would be: how a student is doing on his/her assignments, or how their work compares to that of their classmates. On a less functional angle, it also enhances the aesthetics of the pages, taking the drab tables and giving them a more appealing look.&lt;br /&gt;
&lt;br /&gt;
=Overview of Approach=&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Chart Examples====&lt;br /&gt;
=====Area Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/area_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/areachart.html#Example&lt;br /&gt;
  def area_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['2004', 1000, 400],&lt;br /&gt;
      ['2005', 1170, 460],&lt;br /&gt;
      ['2006', 660, 1120],&lt;br /&gt;
      ['2007', 1030, 540]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts   = { width: 400, height: 240, title: 'Company Performance', hAxis: {title: 'Year', titleTextStyle: {color: '#FF0000'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::AreaChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bar Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bar_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/barchart.html#Example&lt;br /&gt;
  def bar_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows(4)&lt;br /&gt;
    data_table.set_cell(0, 0, '2004')&lt;br /&gt;
    data_table.set_cell(0, 1, 1000)&lt;br /&gt;
    data_table.set_cell(0, 2, 400)&lt;br /&gt;
    data_table.set_cell(1, 0, '2005')&lt;br /&gt;
    data_table.set_cell(1, 1, 1170)&lt;br /&gt;
    data_table.set_cell(1, 2, 460)&lt;br /&gt;
    data_table.set_cell(2, 0, '2006')&lt;br /&gt;
    data_table.set_cell(2, 1, 660)&lt;br /&gt;
    data_table.set_cell(2, 2, 1120)&lt;br /&gt;
    data_table.set_cell(3, 0, '2007')&lt;br /&gt;
    data_table.set_cell(3, 1, 1030)&lt;br /&gt;
    data_table.set_cell(3, 2, 540)&lt;br /&gt;
&lt;br /&gt;
    opts   = { :width =&amp;gt; 400, :height =&amp;gt; 240, :title =&amp;gt; 'Company Performance', vAxis: {title: 'Year', titleTextStyle: {color: 'red'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BarChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bubble Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bubble_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/bubblechart.html&lt;br /&gt;
  def bubble_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'ID')&lt;br /&gt;
    data_table.new_column('number', 'Life Expectancy')&lt;br /&gt;
    data_table.new_column('number', 'Fertility Rate')&lt;br /&gt;
    data_table.new_column('string', 'Region')&lt;br /&gt;
    data_table.new_column('number', 'Population')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['CAN',    80.66,              1.67,      'North America',  33739900],&lt;br /&gt;
      ['DEU',    79.84,              1.36,      'Europe',         81902307],&lt;br /&gt;
      ['DNK',    78.6,               1.84,      'Europe',         5523095],&lt;br /&gt;
      ['EGY',    72.73,              2.78,      'Middle East',    79716203],&lt;br /&gt;
      ['GBR',    80.05,              2,         'Europe',         61801570],&lt;br /&gt;
      ['IRN',    72.49,              1.7,       'Middle East',    73137148],&lt;br /&gt;
      ['IRQ',    68.09,              4.77,      'Middle East',    31090763],&lt;br /&gt;
      ['ISR',    81.55,              2.96,      'Middle East',    7485600],&lt;br /&gt;
      ['RUS',    68.6,               1.54,      'Europe',         141850000],&lt;br /&gt;
      ['USA',    78.09,              2.05,      'North America',  307007000]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts    = {&lt;br /&gt;
      :width =&amp;gt; 800, :height =&amp;gt; 500,&lt;br /&gt;
      :title =&amp;gt; 'Correlation between life expectancy, fertility rate and population of some world countries (2010)',&lt;br /&gt;
      :hAxis =&amp;gt; { :title =&amp;gt; 'Life Expectancy' },&lt;br /&gt;
      :vAxis =&amp;gt; { :title =&amp;gt; 'Fertility Rate'  },&lt;br /&gt;
      :bubble =&amp;gt; { :textStyle =&amp;gt; { :fontSize =&amp;gt; 11 } }&lt;br /&gt;
    }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BubbleChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The resulting chart looks like below.&lt;br /&gt;
[[File:BubbleChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
pie chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.pie(:data =&amp;gt; [20, 35, 45])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Piechart.png]]&lt;br /&gt;
&lt;br /&gt;
These usages come from http://googlecharts.rubyforge.org/. If you want to see more usages, go and visit this site.&lt;br /&gt;
&lt;br /&gt;
===gchartrb===&lt;br /&gt;
gchartrb&amp;lt;ref&amp;gt;http://code.google.com/p/gchartrb/&amp;lt;/ref&amp;gt; is a Ruby wrapper around the Google chart API&amp;lt;ref&amp;gt;http://code.google.com/apis/chart/&amp;lt;/ref&amp;gt;. In our project, we use gchartrb to generate all the bar charts in the visualization. &lt;br /&gt;
&lt;br /&gt;
====installing====&lt;br /&gt;
Installing gchartrb is simple, just include the gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem 'gchartrb', :require =&amp;gt; 'google_chart'&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Examples====&lt;br /&gt;
=====Bar Chart=====&lt;br /&gt;
The following example code would generate a bar chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Bar Chart&lt;br /&gt;
    GoogleChart::BarChart.new('800x200', &amp;quot;Bar Chart&amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
      bc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5], '0000ff'&lt;br /&gt;
      bc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], 'ff0000'&lt;br /&gt;
      bc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,4,5,6], '00ff00'&lt;br /&gt;
      puts &amp;quot;\nBar Chart&amp;quot;&lt;br /&gt;
      puts bc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:BarChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
=====Line Chart=====&lt;br /&gt;
The following example code would generate a line chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Line Chart&lt;br /&gt;
    GoogleChart::LineChart.new('320x200', &amp;quot;Line Chart&amp;quot;, false) do |lc|&lt;br /&gt;
      lc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5,6], '0000ff'&lt;br /&gt;
      lc.show_legend = true&lt;br /&gt;
      lc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], '00ff00'&lt;br /&gt;
      lc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,3,2,1], 'ff0000'&lt;br /&gt;
      lc.axis :y, :range =&amp;gt; [0,6], :color =&amp;gt; 'ff00ff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.axis :x, :range =&amp;gt; [0,6], :color =&amp;gt; '00ffff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.grid :x_step =&amp;gt; 100.0/6.0, :y_step =&amp;gt; 100.0/6.0, :length_segment =&amp;gt; 1, :length_blank =&amp;gt; 0&lt;br /&gt;
      puts &amp;quot;\nLine Chart&amp;quot;&lt;br /&gt;
      puts lc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:AeraChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Circles===&lt;br /&gt;
----&lt;br /&gt;
We use the Circles lightweight JavaScript library generating circular graphs to represent the average scores expressed as percentage with animation.&lt;br /&gt;
&lt;br /&gt;
Here is an example of the circles we use.&lt;br /&gt;
[[File:Circles.png|center]]&lt;br /&gt;
&lt;br /&gt;
For more details about the circles.js, you can refer to https://github.com/lugolabs/circles&lt;br /&gt;
====Usage====&lt;br /&gt;
----&lt;br /&gt;
Include the circles.js or circles.min.js file in your HTML file. There are no dependencies.&lt;br /&gt;
&lt;br /&gt;
And create a placeholder div in your HTML:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;circle&amp;quot; id=&amp;quot;circles-1&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a graph by calling, the id should match id of the placeholder div:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
var myCircle = Circles.create({&lt;br /&gt;
  id:           'circles-1',&lt;br /&gt;
  radius:       60,&lt;br /&gt;
  value:        43,&lt;br /&gt;
  maxValue:     100,&lt;br /&gt;
  width:        10,&lt;br /&gt;
  text:         function(value){return value + '%';},&lt;br /&gt;
  colors:       ['#D3B6C6', '#4B253A'],&lt;br /&gt;
  duration: 	  400,&lt;br /&gt;
  wrpClass:	    'circles-wrp',&lt;br /&gt;
  textClass:	  'circles-text'&lt;br /&gt;
  styleWrapper: true,&lt;br /&gt;
  styleText:    true&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where&lt;br /&gt;
&lt;br /&gt;
* `id` 			    - the DOM element that will hold the graph&lt;br /&gt;
* `radius` 		    - the radius of the circles&lt;br /&gt;
* `value` 		    - init value of the circle (optional, defaults to 0)&lt;br /&gt;
* `maxValue` 	    - maximum value of the circle (optional, defaults to 100)&lt;br /&gt;
* `width` 		    - the width of the ring (optional, has value 10, if not specified)&lt;br /&gt;
* `colors` 		    - an array of colors, with the first item coloring the full circle (optional, it will be `['#EEE', '#F00']` if not specified)&lt;br /&gt;
* `duration` 	    - value in ms of animation's duration; defaults to 500; if 0 or `null` is passed, the animation will not run.&lt;br /&gt;
* `wrpClass` 	    - class name to apply on the generated element wrapping the whole circle.&lt;br /&gt;
* `textClass` 	    - class name to apply on the generated element wrapping the text content.&lt;br /&gt;
* `styleWrapper'   - whether or not to add inline styles to the wrapper element (defaults to true)&lt;br /&gt;
* `styleText`	    - whether or not to add inline styles to the text (defaults to true)&lt;br /&gt;
* `text`                  - the text to display at the center of the graph (optional, the current &amp;quot;htmlified&amp;quot; value will be shown). If `null` or an empty string, no text will be displayed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
API&lt;br /&gt;
----&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateRadius(Number radius)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `radius` (see `spec/responsive.html` for an example on how to create a responsive circle).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateWidth(Number width)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `width`&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateColors(Array colors)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Change `colors` used to draw the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Number value [, Number duration])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Set the value of the circle to `value`.&lt;br /&gt;
Animation will take `duration` ms to execute. If no `duration` is given, default duration set in constructor will be used.&lt;br /&gt;
If you don't want animation, set `duration` to 0.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Boolean force)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Force the redrawing of the circle if `force` is set to **true**. Do nothing otherwise.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getPercent()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the percentage value of the circle, based on its current value and its max value.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getMaxValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the max value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValueFromPercent(Number percentage)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the corresponding value of the circle based on its max value and given `percentage`.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.htmlifyNumber(Number number[, integerPartClass, decimalPartClass])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Visualization in Expertiza=&lt;br /&gt;
This section describes where in Expertiza we can use these visualizations to provide a better user experience. &lt;br /&gt;
The 'Review Score' view of the assignments can be enhanced using these visualization.&lt;br /&gt;
&lt;br /&gt;
We can see by the image below that currently the scores views includes only a large table. From a user experience perspective having a more prioritized view of the scores would be beneficial. Having all the data available for the user to peruse in a table is informative, but when the user wants only to get a quick idea of how they did in an assignment, it would be helpful to have some sort of visualization.&lt;br /&gt;
&lt;br /&gt;
[[File:score_view.png.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The above scoring which is in tabular form can be enhanced with charts.&lt;br /&gt;
&lt;br /&gt;
=Graphical Score Dashboard=&lt;br /&gt;
The scores page was augmented with bar graphs displaying the distributions of each column, as well as a circle icon for the average score for that column. This will allow for easily determining what the reviewers thought of the work, as well as what the range of scores given. The circle graphs with the averages provide a visual for the quality of the work in each of the categories.&lt;br /&gt;
&lt;br /&gt;
[[File:Score_chart.png]]&lt;br /&gt;
&lt;br /&gt;
==New View==&lt;br /&gt;
&lt;br /&gt;
We created a new view under the grades views, called participant_charts. This view is included as a partial in the grades/view_my_scores view. This allows us to not modify any of the existing views and keep the code modular.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Bar Charts==&lt;br /&gt;
&lt;br /&gt;
For the bar charts we constructed a method that, given the score and the type of bar chart, populates an instance variable that contains the charts. The code was included in the grades controller (grades_controller.rb file) and is shown below&lt;br /&gt;
&lt;br /&gt;
    def bar_chart(scores, type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;100x100&amp;quot;, &amp;quot; &amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
          data = scores&lt;br /&gt;
          bc.data &amp;quot;Line green&amp;quot;, data, '990000'&lt;br /&gt;
          #bc.axis :x, :positions =&amp;gt; [0, data.size], :range =&amp;gt; [0,100]&lt;br /&gt;
          bc.axis :y, :range =&amp;gt; [0, data.max] ,:positions =&amp;gt; [data.min, data.max]&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 70/(data.size+1),:bar_spacing =&amp;gt; 1, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
The width of the bars is dependent on the number of scores to show. Assignments with many reviews to show, require smaller bars. This is accomplished by tying the bar_width parameter, to the size of the data.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Circle Charts==&lt;br /&gt;
&lt;br /&gt;
For the circle charts showing the averages of the columns we used a javascript library, circle.js. By simply passing the scores to the .js code in the grades view as shown in the code below. The circle is then rendered automatically in a div block elsewhere in the view named the same as the id: tag below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;% ['review', 'metareview', 'feedback', 'teammate'].each do |type| %&amp;gt;&lt;br /&gt;
      &amp;lt;% if @pscore[type.to_sym][:scores][:avg]%&amp;gt;&lt;br /&gt;
        var myCircle = Circles.create({&lt;br /&gt;
      id:           '&amp;lt;%= &amp;quot;#{type}-circle&amp;quot; %&amp;gt;',&lt;br /&gt;
      radius:       25,&lt;br /&gt;
      value:        &amp;lt;%= @pscore[type.to_sym][:scores][:avg].to_i %&amp;gt;,&lt;br /&gt;
      maxValue:     100,&lt;br /&gt;
      width:        7,&lt;br /&gt;
      text:         '&amp;lt;%=@pscore[type.to_sym][:scores][:avg].to_i%&amp;gt;',&lt;br /&gt;
      colors:       ['#FFEB99', '#FFCC00'],&lt;br /&gt;
      duration:       700,&lt;br /&gt;
      textClass:      'circles-text'&lt;br /&gt;
    });&lt;br /&gt;
&lt;br /&gt;
==Show / Hide stats==&lt;br /&gt;
&lt;br /&gt;
The user might want to hide the stats, with that in mind we included a button to toggle the visibility of the charts. Making use of an existing function, toggleElement, we added a link above the charts table that when clicked hides/shows the charts. The code to accomplish this is shown below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;a href=&amp;quot;#&amp;quot; name='score-chartLink' onClick=&amp;quot;toggleElement('score-chart', 'stats');return false;&amp;quot;&amp;gt;hide stats&amp;lt;/a&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Reliability Metric=&lt;br /&gt;
Based on the uniformity of the review scores, we compiled a reliability metric. This metric encapsulates the level of agreement between the reviews, and should provide a quick at a glance notion of whether reviewers agree on the scoring for the particular assignment, or whether there is a high variance in the scores given. A good reliability score indicates that the grade given to the assignment by the reviewers is to be trusted, whereas a poor reliability score indicates that there was a high level of disagreement in the reviewers and the instructors should perhaps take a closer look at the participant's assignment.&lt;br /&gt;
This reliability score is computed from the standard deviation of the review scores. A standard deviation that's less than 10 will award a good reliability score. A standard deviation between 10 and 20 will award a medium reliability score, whereas a standard deviation greater than 20 will give a poor reliability score.&lt;br /&gt;
===Different Icon colors===&lt;br /&gt;
[[File:Green_icon.png]]&lt;br /&gt;
&lt;br /&gt;
The color of the three bars Icon, and the number of filled bars is representative of the reliability of the reviews.&lt;br /&gt;
Take the case of the green sample icon in the image above, the reviews mostly all agree. Whereas in the following two images, the icon is yellow and red respectively to signify increasingly worrying levels of disparity in review scores.&lt;br /&gt;
&lt;br /&gt;
[[File:Yellow_icon.png]]&lt;br /&gt;
&lt;br /&gt;
[[File:Red_icon.png]]&lt;br /&gt;
&lt;br /&gt;
A similar method to the one used for the bar charts was used. In this case, a horizontal bar chart was created, and the data was dictated by the qualitative score that was passed into the method. This score could be 'good', 'medium' or 'bad'. Based on this string argument the graph is created with the correct number of bars and the correct color.&lt;br /&gt;
&lt;br /&gt;
    def reliability_chart(score,type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;25x20&amp;quot;, &amp;quot; &amp;quot;, :horizontal, false) do |bc|&lt;br /&gt;
          if score == 'good'&lt;br /&gt;
            data = [1,1,1]&lt;br /&gt;
            color = '00ff00'&lt;br /&gt;
          elsif score == 'medium'&lt;br /&gt;
            data = [1,1]&lt;br /&gt;
            color = 'FFCC00'&lt;br /&gt;
          else&lt;br /&gt;
            data = [1]&lt;br /&gt;
            color = '990000'&lt;br /&gt;
          end&lt;br /&gt;
          bc.data &amp;quot;Reliability Symbol&amp;quot;, data, color&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 5,:bar_spacing =&amp;gt; 10, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
      end&lt;br /&gt;
&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97099</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97099"/>
		<updated>2015-05-05T00:56:09Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Project Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Project Description=&lt;br /&gt;
The goal of this project is to present the the data in Expertiza in a more convenient way. Through the use of charts and graphs to enhance certain pages, such as the student's scores page and the instructor's scores page, and allow for the users to get an at-a-glance analysis of the data without having to dive into the tables.&lt;br /&gt;
&lt;br /&gt;
Our project video https://www.youtube.com/watch?v=-Oe9YesiU5Y&amp;amp;feature=youtu.be&lt;br /&gt;
==Purpose==&lt;br /&gt;
The purpose of this project is to add a visualization element to some of the data collected in expertiza. The aim of this is to provide a more intuitive “at-a-glance” idea of the data, some examples would be: how a student is doing on his/her assignments, or how their work compares to that of their classmates. On a less functional angle, it also enhances the aesthetics of the pages, taking the drab tables and giving them a more appealing look.&lt;br /&gt;
&lt;br /&gt;
=Overview of Approach=&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Chart Examples====&lt;br /&gt;
=====Area Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/area_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/areachart.html#Example&lt;br /&gt;
  def area_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['2004', 1000, 400],&lt;br /&gt;
      ['2005', 1170, 460],&lt;br /&gt;
      ['2006', 660, 1120],&lt;br /&gt;
      ['2007', 1030, 540]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts   = { width: 400, height: 240, title: 'Company Performance', hAxis: {title: 'Year', titleTextStyle: {color: '#FF0000'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::AreaChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bar Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bar_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/barchart.html#Example&lt;br /&gt;
  def bar_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows(4)&lt;br /&gt;
    data_table.set_cell(0, 0, '2004')&lt;br /&gt;
    data_table.set_cell(0, 1, 1000)&lt;br /&gt;
    data_table.set_cell(0, 2, 400)&lt;br /&gt;
    data_table.set_cell(1, 0, '2005')&lt;br /&gt;
    data_table.set_cell(1, 1, 1170)&lt;br /&gt;
    data_table.set_cell(1, 2, 460)&lt;br /&gt;
    data_table.set_cell(2, 0, '2006')&lt;br /&gt;
    data_table.set_cell(2, 1, 660)&lt;br /&gt;
    data_table.set_cell(2, 2, 1120)&lt;br /&gt;
    data_table.set_cell(3, 0, '2007')&lt;br /&gt;
    data_table.set_cell(3, 1, 1030)&lt;br /&gt;
    data_table.set_cell(3, 2, 540)&lt;br /&gt;
&lt;br /&gt;
    opts   = { :width =&amp;gt; 400, :height =&amp;gt; 240, :title =&amp;gt; 'Company Performance', vAxis: {title: 'Year', titleTextStyle: {color: 'red'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BarChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bubble Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bubble_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/bubblechart.html&lt;br /&gt;
  def bubble_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'ID')&lt;br /&gt;
    data_table.new_column('number', 'Life Expectancy')&lt;br /&gt;
    data_table.new_column('number', 'Fertility Rate')&lt;br /&gt;
    data_table.new_column('string', 'Region')&lt;br /&gt;
    data_table.new_column('number', 'Population')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['CAN',    80.66,              1.67,      'North America',  33739900],&lt;br /&gt;
      ['DEU',    79.84,              1.36,      'Europe',         81902307],&lt;br /&gt;
      ['DNK',    78.6,               1.84,      'Europe',         5523095],&lt;br /&gt;
      ['EGY',    72.73,              2.78,      'Middle East',    79716203],&lt;br /&gt;
      ['GBR',    80.05,              2,         'Europe',         61801570],&lt;br /&gt;
      ['IRN',    72.49,              1.7,       'Middle East',    73137148],&lt;br /&gt;
      ['IRQ',    68.09,              4.77,      'Middle East',    31090763],&lt;br /&gt;
      ['ISR',    81.55,              2.96,      'Middle East',    7485600],&lt;br /&gt;
      ['RUS',    68.6,               1.54,      'Europe',         141850000],&lt;br /&gt;
      ['USA',    78.09,              2.05,      'North America',  307007000]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts    = {&lt;br /&gt;
      :width =&amp;gt; 800, :height =&amp;gt; 500,&lt;br /&gt;
      :title =&amp;gt; 'Correlation between life expectancy, fertility rate and population of some world countries (2010)',&lt;br /&gt;
      :hAxis =&amp;gt; { :title =&amp;gt; 'Life Expectancy' },&lt;br /&gt;
      :vAxis =&amp;gt; { :title =&amp;gt; 'Fertility Rate'  },&lt;br /&gt;
      :bubble =&amp;gt; { :textStyle =&amp;gt; { :fontSize =&amp;gt; 11 } }&lt;br /&gt;
    }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BubbleChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The resulting chart looks like below.&lt;br /&gt;
[[File:BubbleChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
pie chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.pie(:data =&amp;gt; [20, 35, 45])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Piechart.png]]&lt;br /&gt;
&lt;br /&gt;
These usages come from http://googlecharts.rubyforge.org/. If you want to see more usages, go and visit this site.&lt;br /&gt;
&lt;br /&gt;
===gchartrb===&lt;br /&gt;
gchartrb&amp;lt;ref&amp;gt;http://code.google.com/p/gchartrb/&amp;lt;/ref&amp;gt; is a Ruby wrapper around the Google chart API&amp;lt;ref&amp;gt;http://code.google.com/apis/chart/&amp;lt;/ref&amp;gt;. In our project, we use gchartrb to generate all the bar charts in the visualization. &lt;br /&gt;
&lt;br /&gt;
====installing====&lt;br /&gt;
Installing gchartrb is simple, just include the gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem 'gchartrb', :require =&amp;gt; 'google_chart'&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Examples====&lt;br /&gt;
=====Bar Chart=====&lt;br /&gt;
The following example code would generate a bar chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Bar Chart&lt;br /&gt;
    GoogleChart::BarChart.new('800x200', &amp;quot;Bar Chart&amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
      bc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5], '0000ff'&lt;br /&gt;
      bc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], 'ff0000'&lt;br /&gt;
      bc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,4,5,6], '00ff00'&lt;br /&gt;
      puts &amp;quot;\nBar Chart&amp;quot;&lt;br /&gt;
      puts bc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:BarChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
=====Line Chart=====&lt;br /&gt;
The following example code would generate a line chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Line Chart&lt;br /&gt;
    GoogleChart::LineChart.new('320x200', &amp;quot;Line Chart&amp;quot;, false) do |lc|&lt;br /&gt;
      lc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5,6], '0000ff'&lt;br /&gt;
      lc.show_legend = true&lt;br /&gt;
      lc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], '00ff00'&lt;br /&gt;
      lc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,3,2,1], 'ff0000'&lt;br /&gt;
      lc.axis :y, :range =&amp;gt; [0,6], :color =&amp;gt; 'ff00ff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.axis :x, :range =&amp;gt; [0,6], :color =&amp;gt; '00ffff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.grid :x_step =&amp;gt; 100.0/6.0, :y_step =&amp;gt; 100.0/6.0, :length_segment =&amp;gt; 1, :length_blank =&amp;gt; 0&lt;br /&gt;
      puts &amp;quot;\nLine Chart&amp;quot;&lt;br /&gt;
      puts lc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:AeraChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Circles===&lt;br /&gt;
----&lt;br /&gt;
We use the Circles lightweight JavaScript library generating circular graphs to represent the average scores expressed as percentage with animation.&lt;br /&gt;
&lt;br /&gt;
Here is an example of the circles we use.&lt;br /&gt;
[[File:Circles.png|center]]&lt;br /&gt;
&lt;br /&gt;
For more details about the circles.js, you can refer to https://github.com/lugolabs/circles&lt;br /&gt;
====Usage====&lt;br /&gt;
----&lt;br /&gt;
Include the circles.js or circles.min.js file in your HTML file. There are no dependencies.&lt;br /&gt;
&lt;br /&gt;
And create a placeholder div in your HTML:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;circle&amp;quot; id=&amp;quot;circles-1&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a graph by calling, the id should match id of the placeholder div:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
var myCircle = Circles.create({&lt;br /&gt;
  id:           'circles-1',&lt;br /&gt;
  radius:       60,&lt;br /&gt;
  value:        43,&lt;br /&gt;
  maxValue:     100,&lt;br /&gt;
  width:        10,&lt;br /&gt;
  text:         function(value){return value + '%';},&lt;br /&gt;
  colors:       ['#D3B6C6', '#4B253A'],&lt;br /&gt;
  duration: 	  400,&lt;br /&gt;
  wrpClass:	    'circles-wrp',&lt;br /&gt;
  textClass:	  'circles-text'&lt;br /&gt;
  styleWrapper: true,&lt;br /&gt;
  styleText:    true&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where&lt;br /&gt;
&lt;br /&gt;
* `id` 			    - the DOM element that will hold the graph&lt;br /&gt;
* `radius` 		    - the radius of the circles&lt;br /&gt;
* `value` 		    - init value of the circle (optional, defaults to 0)&lt;br /&gt;
* `maxValue` 	    - maximum value of the circle (optional, defaults to 100)&lt;br /&gt;
* `width` 		    - the width of the ring (optional, has value 10, if not specified)&lt;br /&gt;
* `colors` 		    - an array of colors, with the first item coloring the full circle (optional, it will be `['#EEE', '#F00']` if not specified)&lt;br /&gt;
* `duration` 	    - value in ms of animation's duration; defaults to 500; if 0 or `null` is passed, the animation will not run.&lt;br /&gt;
* `wrpClass` 	    - class name to apply on the generated element wrapping the whole circle.&lt;br /&gt;
* `textClass` 	    - class name to apply on the generated element wrapping the text content.&lt;br /&gt;
* `styleWrapper'   - whether or not to add inline styles to the wrapper element (defaults to true)&lt;br /&gt;
* `styleText`	    - whether or not to add inline styles to the text (defaults to true)&lt;br /&gt;
* `text`                  - the text to display at the center of the graph (optional, the current &amp;quot;htmlified&amp;quot; value will be shown). If `null` or an empty string, no text will be displayed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
API&lt;br /&gt;
----&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateRadius(Number radius)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `radius` (see `spec/responsive.html` for an example on how to create a responsive circle).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateWidth(Number width)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `width`&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateColors(Array colors)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Change `colors` used to draw the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Number value [, Number duration])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Set the value of the circle to `value`.&lt;br /&gt;
Animation will take `duration` ms to execute. If no `duration` is given, default duration set in constructor will be used.&lt;br /&gt;
If you don't want animation, set `duration` to 0.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Boolean force)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Force the redrawing of the circle if `force` is set to **true**. Do nothing otherwise.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getPercent()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the percentage value of the circle, based on its current value and its max value.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getMaxValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the max value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValueFromPercent(Number percentage)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the corresponding value of the circle based on its max value and given `percentage`.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.htmlifyNumber(Number number[, integerPartClass, decimalPartClass])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Visualization in Expertiza=&lt;br /&gt;
This section describes where in Expertiza we can use these visualizations to provide a better user experience. &lt;br /&gt;
The 'Review Score' view of the assignments can be enhanced using these visualization.&lt;br /&gt;
&lt;br /&gt;
We can see by the image below that currently the scores views includes only a large table. From a user experience perspective having a more prioritized view of the scores would be beneficial. Having all the data available for the user to peruse in a table is informative, but when the user wants only to get a quick idea of how they did in an assignment, it would be helpful to have some sort of visualization.&lt;br /&gt;
&lt;br /&gt;
[[File:score_view.png.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The above scoring which is in tabular form can be enhanced with charts.&lt;br /&gt;
&lt;br /&gt;
=Graphical Score Dashboard=&lt;br /&gt;
The scores page was augmented with bar graphs displaying the distributions of each column, as well as a circle icon for the average score for that column. This will allow for easily determining what the reviewers thought of the work, as well as what the range of scores given. The circle graphs with the averages provide a visual for the quality of the work in each of the categories.&lt;br /&gt;
&lt;br /&gt;
[[File:Score_chart.png]]&lt;br /&gt;
&lt;br /&gt;
==New View==&lt;br /&gt;
&lt;br /&gt;
We created a new view under the grades views, called participant_charts. This view is included as a partial in the grades/view_my_scores view. This allows us to not modify any of the existing views and keep the code modular.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Bar Charts==&lt;br /&gt;
&lt;br /&gt;
For the bar charts we constructed a method that, given the score and the type of bar chart, populates an instance variable that contains the charts. The code was included in the grades controller (grades_controller.rb file) and is shown below&lt;br /&gt;
&lt;br /&gt;
    def bar_chart(scores, type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;100x100&amp;quot;, &amp;quot; &amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
          data = scores&lt;br /&gt;
          bc.data &amp;quot;Line green&amp;quot;, data, '990000'&lt;br /&gt;
          #bc.axis :x, :positions =&amp;gt; [0, data.size], :range =&amp;gt; [0,100]&lt;br /&gt;
          bc.axis :y, :range =&amp;gt; [0, data.max] ,:positions =&amp;gt; [data.min, data.max]&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 70/(data.size+1),:bar_spacing =&amp;gt; 1, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
The width of the bars is dependent on the number of scores to show. Assignments with many reviews to show, require smaller bars. This is accomplished by tying the bar_width parameter, to the size of the data.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Circle Charts==&lt;br /&gt;
&lt;br /&gt;
For the circle charts showing the averages of the columns we used a javascript library, circle.js. By simply passing the scores to the .js code in the grades view as shown in the code below. The circle is then rendered automatically in a div block elsewhere in the view named the same as the id: tag below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;% ['review', 'metareview', 'feedback', 'teammate'].each do |type| %&amp;gt;&lt;br /&gt;
      &amp;lt;% if @pscore[type.to_sym][:scores][:avg]%&amp;gt;&lt;br /&gt;
        var myCircle = Circles.create({&lt;br /&gt;
      id:           '&amp;lt;%= &amp;quot;#{type}-circle&amp;quot; %&amp;gt;',&lt;br /&gt;
      radius:       25,&lt;br /&gt;
      value:        &amp;lt;%= @pscore[type.to_sym][:scores][:avg].to_i %&amp;gt;,&lt;br /&gt;
      maxValue:     100,&lt;br /&gt;
      width:        7,&lt;br /&gt;
      text:         '&amp;lt;%=@pscore[type.to_sym][:scores][:avg].to_i%&amp;gt;',&lt;br /&gt;
      colors:       ['#FFEB99', '#FFCC00'],&lt;br /&gt;
      duration:       700,&lt;br /&gt;
      textClass:      'circles-text'&lt;br /&gt;
    });&lt;br /&gt;
&lt;br /&gt;
==Show / Hide stats==&lt;br /&gt;
&lt;br /&gt;
The user might want to hide the stats, with that in mind we included a button to toggle the visibility of the charts. Making use of an existing function, toggleElement, we added a link above the charts table that when clicked hides/shows the charts. The code to accomplish this is shown below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;a href=&amp;quot;#&amp;quot; name='score-chartLink' onClick=&amp;quot;toggleElement('score-chart', 'stats');return false;&amp;quot;&amp;gt;hide stats&amp;lt;/a&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Reliability Metric=&lt;br /&gt;
Based on the uniformity of the review scores, we compiled a reliability metric. This metric encapsulates the level of agreement between the reviews, and should provide a quick at a glance notion of whether reviewers agree on the scoring for the particular assignment, or whether there is a high variance in the scores given. A good reliability score indicates that the grade given to the assignment by the reviewers is to be trusted, whereas a poor reliability score indicates that there was a high level of disagreement in the reviewers and the instructors should perhaps take a closer look at the participant's assignment.&lt;br /&gt;
This reliability score is computed from the standard deviation of the review scores. A standard deviation that's less than 10 will award a good reliability score. A standard deviation between 10 and 20 will award a medium reliability score, whereas a standard deviation greater than 20 will give a poor reliability score.&lt;br /&gt;
===Different Icon colors===&lt;br /&gt;
[[File:Green_icon.png]]&lt;br /&gt;
&lt;br /&gt;
The color of the three bars Icon, and the number of filled bars is representative of the reliability of the reviews.&lt;br /&gt;
Take the case of the green sample icon in the image above, the reviews mostly all agree. Whereas in the following two images, the icon is yellow and red respectively to signify increasingly worrying levels of disparity in review scores.&lt;br /&gt;
&lt;br /&gt;
[[File:Yellow_icon.png]]&lt;br /&gt;
&lt;br /&gt;
[[File:Red_icon.png]]&lt;br /&gt;
&lt;br /&gt;
A similar method to the one used for the bar charts was used. In this case, a horizontal bar chart was created, and the data was dictated by the qualitative score that was passed into the method. This score could be 'good', 'medium' or 'bad'. Based on this string argument the graph is created with the correct number of bars and the correct color.&lt;br /&gt;
&lt;br /&gt;
    def reliability_chart(score,type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;25x20&amp;quot;, &amp;quot; &amp;quot;, :horizontal, false) do |bc|&lt;br /&gt;
          if score == 'good'&lt;br /&gt;
            data = [1,1,1]&lt;br /&gt;
            color = '00ff00'&lt;br /&gt;
          elsif score == 'medium'&lt;br /&gt;
            data = [1,1]&lt;br /&gt;
            color = 'FFCC00'&lt;br /&gt;
          else&lt;br /&gt;
            data = [1]&lt;br /&gt;
            color = '990000'&lt;br /&gt;
          end&lt;br /&gt;
          bc.data &amp;quot;Reliability Symbol&amp;quot;, data, color&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 5,:bar_spacing =&amp;gt; 10, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
      end&lt;br /&gt;
&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97076</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97076"/>
		<updated>2015-05-03T20:48:55Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Circles */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Project Description=&lt;br /&gt;
The goal of this project is to present the the data in Expertiza in a more convenient way. Through the use of charts and graphs to enhance certain pages, such as the student's scores page and the instructor's scores page, and allow for the users to get an at-a-glance analysis of the data without having to dive into the tables.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
The purpose of this project is to add a visualization element to some of the data collected in expertiza. The aim of this is to provide a more intuitive “at-a-glance” idea of the data, some examples would be: how a student is doing on his/her assignments, or how their work compares to that of their classmates. On a less functional angle, it also enhances the aesthetics of the pages, taking the drab tables and giving them a more appealing look.&lt;br /&gt;
&lt;br /&gt;
=Overview of Approach=&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Chart Examples====&lt;br /&gt;
=====Area Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/area_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/areachart.html#Example&lt;br /&gt;
  def area_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['2004', 1000, 400],&lt;br /&gt;
      ['2005', 1170, 460],&lt;br /&gt;
      ['2006', 660, 1120],&lt;br /&gt;
      ['2007', 1030, 540]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts   = { width: 400, height: 240, title: 'Company Performance', hAxis: {title: 'Year', titleTextStyle: {color: '#FF0000'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::AreaChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bar Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bar_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/barchart.html#Example&lt;br /&gt;
  def bar_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows(4)&lt;br /&gt;
    data_table.set_cell(0, 0, '2004')&lt;br /&gt;
    data_table.set_cell(0, 1, 1000)&lt;br /&gt;
    data_table.set_cell(0, 2, 400)&lt;br /&gt;
    data_table.set_cell(1, 0, '2005')&lt;br /&gt;
    data_table.set_cell(1, 1, 1170)&lt;br /&gt;
    data_table.set_cell(1, 2, 460)&lt;br /&gt;
    data_table.set_cell(2, 0, '2006')&lt;br /&gt;
    data_table.set_cell(2, 1, 660)&lt;br /&gt;
    data_table.set_cell(2, 2, 1120)&lt;br /&gt;
    data_table.set_cell(3, 0, '2007')&lt;br /&gt;
    data_table.set_cell(3, 1, 1030)&lt;br /&gt;
    data_table.set_cell(3, 2, 540)&lt;br /&gt;
&lt;br /&gt;
    opts   = { :width =&amp;gt; 400, :height =&amp;gt; 240, :title =&amp;gt; 'Company Performance', vAxis: {title: 'Year', titleTextStyle: {color: 'red'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BarChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=====Bubble Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bubble_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/bubblechart.html&lt;br /&gt;
  def bubble_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'ID')&lt;br /&gt;
    data_table.new_column('number', 'Life Expectancy')&lt;br /&gt;
    data_table.new_column('number', 'Fertility Rate')&lt;br /&gt;
    data_table.new_column('string', 'Region')&lt;br /&gt;
    data_table.new_column('number', 'Population')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['CAN',    80.66,              1.67,      'North America',  33739900],&lt;br /&gt;
      ['DEU',    79.84,              1.36,      'Europe',         81902307],&lt;br /&gt;
      ['DNK',    78.6,               1.84,      'Europe',         5523095],&lt;br /&gt;
      ['EGY',    72.73,              2.78,      'Middle East',    79716203],&lt;br /&gt;
      ['GBR',    80.05,              2,         'Europe',         61801570],&lt;br /&gt;
      ['IRN',    72.49,              1.7,       'Middle East',    73137148],&lt;br /&gt;
      ['IRQ',    68.09,              4.77,      'Middle East',    31090763],&lt;br /&gt;
      ['ISR',    81.55,              2.96,      'Middle East',    7485600],&lt;br /&gt;
      ['RUS',    68.6,               1.54,      'Europe',         141850000],&lt;br /&gt;
      ['USA',    78.09,              2.05,      'North America',  307007000]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts    = {&lt;br /&gt;
      :width =&amp;gt; 800, :height =&amp;gt; 500,&lt;br /&gt;
      :title =&amp;gt; 'Correlation between life expectancy, fertility rate and population of some world countries (2010)',&lt;br /&gt;
      :hAxis =&amp;gt; { :title =&amp;gt; 'Life Expectancy' },&lt;br /&gt;
      :vAxis =&amp;gt; { :title =&amp;gt; 'Fertility Rate'  },&lt;br /&gt;
      :bubble =&amp;gt; { :textStyle =&amp;gt; { :fontSize =&amp;gt; 11 } }&lt;br /&gt;
    }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BubbleChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The resulting chart looks like below.&lt;br /&gt;
[[File:BubbleChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
pie chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.pie(:data =&amp;gt; [20, 35, 45])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Piechart.png]]&lt;br /&gt;
&lt;br /&gt;
These usages come from http://googlecharts.rubyforge.org/. If you want to see more usages, go and visit this site.&lt;br /&gt;
&lt;br /&gt;
===gchartrb===&lt;br /&gt;
gchartrb&amp;lt;ref&amp;gt;http://code.google.com/p/gchartrb/&amp;lt;/ref&amp;gt; is a Ruby wrapper around the Google chart API&amp;lt;ref&amp;gt;http://code.google.com/apis/chart/&amp;lt;/ref&amp;gt;. In our project, we use gchartrb to generate all the bar charts in the visualization. &lt;br /&gt;
&lt;br /&gt;
====installing====&lt;br /&gt;
Installing gchartrb is simple, just include the gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem 'gchartrb', :require =&amp;gt; 'google_chart'&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Examples====&lt;br /&gt;
=====Bar Chart=====&lt;br /&gt;
The following example code would generate a bar chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Bar Chart&lt;br /&gt;
    GoogleChart::BarChart.new('800x200', &amp;quot;Bar Chart&amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
      bc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5], '0000ff'&lt;br /&gt;
      bc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], 'ff0000'&lt;br /&gt;
      bc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,4,5,6], '00ff00'&lt;br /&gt;
      puts &amp;quot;\nBar Chart&amp;quot;&lt;br /&gt;
      puts bc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:BarChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
=====Line Chart=====&lt;br /&gt;
The following example code would generate a line chart.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Line Chart&lt;br /&gt;
    GoogleChart::LineChart.new('320x200', &amp;quot;Line Chart&amp;quot;, false) do |lc|&lt;br /&gt;
      lc.data &amp;quot;Trend 1&amp;quot;, [5,4,3,1,3,5,6], '0000ff'&lt;br /&gt;
      lc.show_legend = true&lt;br /&gt;
      lc.data &amp;quot;Trend 2&amp;quot;, [1,2,3,4,5,6], '00ff00'&lt;br /&gt;
      lc.data &amp;quot;Trend 3&amp;quot;, [6,5,4,3,2,1], 'ff0000'&lt;br /&gt;
      lc.axis :y, :range =&amp;gt; [0,6], :color =&amp;gt; 'ff00ff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.axis :x, :range =&amp;gt; [0,6], :color =&amp;gt; '00ffff', :font_size =&amp;gt; 16, :alignment =&amp;gt; :center&lt;br /&gt;
      lc.grid :x_step =&amp;gt; 100.0/6.0, :y_step =&amp;gt; 100.0/6.0, :length_segment =&amp;gt; 1, :length_blank =&amp;gt; 0&lt;br /&gt;
      puts &amp;quot;\nLine Chart&amp;quot;&lt;br /&gt;
      puts lc.to_url&lt;br /&gt;
    end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
The bar chart would look like below.&lt;br /&gt;
[[File:AeraChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===Circles===&lt;br /&gt;
----&lt;br /&gt;
We use the Circles lightweight JavaScript library generating circular graphs to represent the average scores expressed as percentage with animation.&lt;br /&gt;
&lt;br /&gt;
Here is an example of the circles we use.&lt;br /&gt;
[[File:Circles.png|center]]&lt;br /&gt;
&lt;br /&gt;
For more details about the circles.js, you can refer to https://github.com/lugolabs/circles&lt;br /&gt;
====Usage====&lt;br /&gt;
----&lt;br /&gt;
Include the circles.js or circles.min.js file in your HTML file. There are no dependencies.&lt;br /&gt;
&lt;br /&gt;
And create a placeholder div in your HTML:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div class=&amp;quot;circle&amp;quot; id=&amp;quot;circles-1&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Create a graph by calling, the id should match id of the placeholder div:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
var myCircle = Circles.create({&lt;br /&gt;
  id:           'circles-1',&lt;br /&gt;
  radius:       60,&lt;br /&gt;
  value:        43,&lt;br /&gt;
  maxValue:     100,&lt;br /&gt;
  width:        10,&lt;br /&gt;
  text:         function(value){return value + '%';},&lt;br /&gt;
  colors:       ['#D3B6C6', '#4B253A'],&lt;br /&gt;
  duration: 	  400,&lt;br /&gt;
  wrpClass:	    'circles-wrp',&lt;br /&gt;
  textClass:	  'circles-text'&lt;br /&gt;
  styleWrapper: true,&lt;br /&gt;
  styleText:    true&lt;br /&gt;
});&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
where&lt;br /&gt;
&lt;br /&gt;
* `id` 			    - the DOM element that will hold the graph&lt;br /&gt;
* `radius` 		    - the radius of the circles&lt;br /&gt;
* `value` 		    - init value of the circle (optional, defaults to 0)&lt;br /&gt;
* `maxValue` 	    - maximum value of the circle (optional, defaults to 100)&lt;br /&gt;
* `width` 		    - the width of the ring (optional, has value 10, if not specified)&lt;br /&gt;
* `colors` 		    - an array of colors, with the first item coloring the full circle (optional, it will be `['#EEE', '#F00']` if not specified)&lt;br /&gt;
* `duration` 	    - value in ms of animation's duration; defaults to 500; if 0 or `null` is passed, the animation will not run.&lt;br /&gt;
* `wrpClass` 	    - class name to apply on the generated element wrapping the whole circle.&lt;br /&gt;
* `textClass` 	    - class name to apply on the generated element wrapping the text content.&lt;br /&gt;
* `styleWrapper'   - whether or not to add inline styles to the wrapper element (defaults to true)&lt;br /&gt;
* `styleText`	    - whether or not to add inline styles to the text (defaults to true)&lt;br /&gt;
* `text`                  - the text to display at the center of the graph (optional, the current &amp;quot;htmlified&amp;quot; value will be shown). If `null` or an empty string, no text will be displayed.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
API&lt;br /&gt;
----&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateRadius(Number radius)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `radius` (see `spec/responsive.html` for an example on how to create a responsive circle).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateWidth(Number width)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Regenerates the circle with the given `width`&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.updateColors(Array colors)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Change `colors` used to draw the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Number value [, Number duration])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Set the value of the circle to `value`.&lt;br /&gt;
Animation will take `duration` ms to execute. If no `duration` is given, default duration set in constructor will be used.&lt;br /&gt;
If you don't want animation, set `duration` to 0.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.update(Boolean force)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Force the redrawing of the circle if `force` is set to **true**. Do nothing otherwise.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getPercent()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the percentage value of the circle, based on its current value and its max value.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getMaxValue()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the max value of the circle.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.getValueFromPercent(Number percentage)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Returns the corresponding value of the circle based on its max value and given `percentage`.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
myCircle.htmlifyNumber(Number number[, integerPartClass, decimalPartClass])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Visualization in Expertiza=&lt;br /&gt;
This section describes where in Expertiza we can use these visualizations to provide a better user experience. &lt;br /&gt;
The 'Review Score' view of the assignments can be enhanced using these visualization.&lt;br /&gt;
&lt;br /&gt;
We can see by the image below that currently the scores views includes only a large table. From a user experience perspective having a more prioritized view of the scores would be beneficial. Having all the data available for the user to peruse in a table is informative, but when the user wants only to get a quick idea of how they did in an assignment, it would be helpful to have some sort of visualization.&lt;br /&gt;
&lt;br /&gt;
[[File:score_view.png.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The above scoring which is in tabular form can be enhanced with charts.&lt;br /&gt;
&lt;br /&gt;
=Graphical Score Dashboard=&lt;br /&gt;
The scores page was augmented with bar graphs displaying the distributions of each column, as well as a circle icon for the average score for that column. This will allow for easily determining what the reviewers thought of the work, as well as what the range of scores given. The circle graphs with the averages provide a visual for the quality of the work in each of the categories.&lt;br /&gt;
&lt;br /&gt;
[[File:Score_chart.png]]&lt;br /&gt;
&lt;br /&gt;
==New View==&lt;br /&gt;
&lt;br /&gt;
We created a new view under the grades views, called participant_charts. This view is included as a partial in the grades/view_my_scores view. This allows us to not modify any of the existing views and keep the code modular.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Bar Charts==&lt;br /&gt;
&lt;br /&gt;
For the bar charts we constructed a method that, given the score and the type of bar chart, populates an instance variable that contains the charts. The code was included in the grades controller (grades_controller.rb file) and is shown below&lt;br /&gt;
&lt;br /&gt;
    def bar_chart(scores, type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;100x100&amp;quot;, &amp;quot; &amp;quot;, :vertical, false) do |bc|&lt;br /&gt;
          data = scores&lt;br /&gt;
          bc.data &amp;quot;Line green&amp;quot;, data, '990000'&lt;br /&gt;
          #bc.axis :x, :positions =&amp;gt; [0, data.size], :range =&amp;gt; [0,100]&lt;br /&gt;
          bc.axis :y, :range =&amp;gt; [0, data.max] ,:positions =&amp;gt; [data.min, data.max]&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 70/(data.size+1),:bar_spacing =&amp;gt; 1, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
&lt;br /&gt;
The width of the bars is dependent on the number of scores to show. Assignments with many reviews to show, require smaller bars. This is accomplished by tying the bar_width parameter, to the size of the data.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Circle Charts==&lt;br /&gt;
&lt;br /&gt;
For the circle charts showing the averages of the columns we used a javascript library, circle.js. By simply passing the scores to the .js code in the grades view as shown in the code below. The circle is then rendered automatically in a div block elsewhere in the view named the same as the id: tag below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;% ['review', 'metareview', 'feedback', 'teammate'].each do |type| %&amp;gt;&lt;br /&gt;
      &amp;lt;% if @pscore[type.to_sym][:scores][:avg]%&amp;gt;&lt;br /&gt;
        var myCircle = Circles.create({&lt;br /&gt;
      id:           '&amp;lt;%= &amp;quot;#{type}-circle&amp;quot; %&amp;gt;',&lt;br /&gt;
      radius:       25,&lt;br /&gt;
      value:        &amp;lt;%= @pscore[type.to_sym][:scores][:avg].to_i %&amp;gt;,&lt;br /&gt;
      maxValue:     100,&lt;br /&gt;
      width:        7,&lt;br /&gt;
      text:         '&amp;lt;%=@pscore[type.to_sym][:scores][:avg].to_i%&amp;gt;',&lt;br /&gt;
      colors:       ['#FFEB99', '#FFCC00'],&lt;br /&gt;
      duration:       700,&lt;br /&gt;
      textClass:      'circles-text'&lt;br /&gt;
    });&lt;br /&gt;
&lt;br /&gt;
==Show / Hide stats==&lt;br /&gt;
&lt;br /&gt;
The user might want to hide the stats, with that in mind we included a button to toggle the visibility of the charts. Making use of an existing function, toggleElement, we added a link above the charts table that when clicked hides/shows the charts. The code to accomplish this is shown below&lt;br /&gt;
&lt;br /&gt;
    &amp;lt;a href=&amp;quot;#&amp;quot; name='score-chartLink' onClick=&amp;quot;toggleElement('score-chart', 'stats');return false;&amp;quot;&amp;gt;hide stats&amp;lt;/a&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Reliability Metric=&lt;br /&gt;
Based on the uniformity of the review scores, we compiled a reliability metric. This metric encapsulates the level of agreement between the reviews, and should provide a quick at a glance notion of whether reviewers agree on the scoring for the particular assignment, or whether there is a high variance in the scores given. A good reliability score indicates that the grade given to the assignment by the reviewers is to be trusted, whereas a poor reliability score indicates that there was a high level of disagreement in the reviewers and the instructors should perhaps take a closer look at the participant's assignment.&lt;br /&gt;
This reliability score is computed from the standard deviation of the review scores. A standard deviation that's less than 10 will award a good reliability score. A standard deviation between 10 and 20 will award a medium reliability score, whereas a standard deviation greater than 20 will give a poor reliability score.&lt;br /&gt;
===Different Icon colors===&lt;br /&gt;
[[File:Green_icon.png]]&lt;br /&gt;
&lt;br /&gt;
The color of the three bars Icon, and the number of filled bars is representative of the reliability of the reviews.&lt;br /&gt;
Take the case of the green sample icon in the image above, the reviews mostly all agree. Whereas in the following two images, the icon is yellow and red respectively to signify increasingly worrying levels of disparity in review scores.&lt;br /&gt;
&lt;br /&gt;
[[File:Yellow_icon.png]]&lt;br /&gt;
&lt;br /&gt;
[[File:Red_icon.png]]&lt;br /&gt;
&lt;br /&gt;
A similar method to the one used for the bar charts was used. In this case, a horizontal bar chart was created, and the data was dictated by the qualitative score that was passed into the method. This score could be 'good', 'medium' or 'bad'. Based on this string argument the graph is created with the correct number of bars and the correct color.&lt;br /&gt;
&lt;br /&gt;
    def reliability_chart(score,type)&lt;br /&gt;
        GoogleChart::BarChart.new(&amp;quot;25x20&amp;quot;, &amp;quot; &amp;quot;, :horizontal, false) do |bc|&lt;br /&gt;
          if score == 'good'&lt;br /&gt;
            data = [1,1,1]&lt;br /&gt;
            color = '00ff00'&lt;br /&gt;
          elsif score == 'medium'&lt;br /&gt;
            data = [1,1]&lt;br /&gt;
            color = 'FFCC00'&lt;br /&gt;
          else&lt;br /&gt;
            data = [1]&lt;br /&gt;
            color = '990000'&lt;br /&gt;
          end&lt;br /&gt;
          bc.data &amp;quot;Reliability Symbol&amp;quot;, data, color&lt;br /&gt;
          bc.show_legend = false&lt;br /&gt;
          bc.stacked = false&lt;br /&gt;
          bc.width_spacing_options({:bar_width =&amp;gt; 5,:bar_spacing =&amp;gt; 10, :group_spacing =&amp;gt; 1})&lt;br /&gt;
          bc.data_encoding = :extended&lt;br /&gt;
          @grades_bar_charts[type.to_sym] = (bc.to_url)&lt;br /&gt;
        end&lt;br /&gt;
      end&lt;br /&gt;
&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Circles.png&amp;diff=97071</id>
		<title>File:Circles.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Circles.png&amp;diff=97071"/>
		<updated>2015-05-03T20:41:43Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: uploaded a new version of &amp;amp;quot;File:Circles.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Circles.png&amp;diff=97070</id>
		<title>File:Circles.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Circles.png&amp;diff=97070"/>
		<updated>2015-05-03T20:37:42Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97050</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=97050"/>
		<updated>2015-05-03T20:13:58Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
The goal of this project is to present the the data in Expertiza in a more convenient way. Through the use of charts and graphs to enhance certain pages, such as the student's scores page and the instructor's scores page, and allow for the users to get an at-a-glance analysis of the data without having to dive into the tables.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
The purpose of this project is to add a visualization element to some of the data collected in expertiza. The aim of this is to provide a more intuitive “at-a-glance” idea of the data, some examples would be: how a student is doing on his/her assignments, or how their work compares to that of their classmates. On a less functional angle, it also enhances the aesthetics of the pages, taking the drab tables and giving them a more appealing look.&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Chart Examples====&lt;br /&gt;
=====Area Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/area_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/areachart.html#Example&lt;br /&gt;
  def area_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['2004', 1000, 400],&lt;br /&gt;
      ['2005', 1170, 460],&lt;br /&gt;
      ['2006', 660, 1120],&lt;br /&gt;
      ['2007', 1030, 540]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts   = { width: 400, height: 240, title: 'Company Performance', hAxis: {title: 'Year', titleTextStyle: {color: '#FF0000'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::AreaChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The resulting chart looks like below.&lt;br /&gt;
[[File:AeraChart.png|center]]&lt;br /&gt;
=====Bar Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bar_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/barchart.html#Example&lt;br /&gt;
  def bar_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'Year')&lt;br /&gt;
    data_table.new_column('number', 'Sales')&lt;br /&gt;
    data_table.new_column('number', 'Expenses')&lt;br /&gt;
    data_table.add_rows(4)&lt;br /&gt;
    data_table.set_cell(0, 0, '2004')&lt;br /&gt;
    data_table.set_cell(0, 1, 1000)&lt;br /&gt;
    data_table.set_cell(0, 2, 400)&lt;br /&gt;
    data_table.set_cell(1, 0, '2005')&lt;br /&gt;
    data_table.set_cell(1, 1, 1170)&lt;br /&gt;
    data_table.set_cell(1, 2, 460)&lt;br /&gt;
    data_table.set_cell(2, 0, '2006')&lt;br /&gt;
    data_table.set_cell(2, 1, 660)&lt;br /&gt;
    data_table.set_cell(2, 2, 1120)&lt;br /&gt;
    data_table.set_cell(3, 0, '2007')&lt;br /&gt;
    data_table.set_cell(3, 1, 1030)&lt;br /&gt;
    data_table.set_cell(3, 2, 540)&lt;br /&gt;
&lt;br /&gt;
    opts   = { :width =&amp;gt; 400, :height =&amp;gt; 240, :title =&amp;gt; 'Company Performance', vAxis: {title: 'Year', titleTextStyle: {color: 'red'}} }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BarChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The resulting chart looks like below.&lt;br /&gt;
[[File:BarChart.png|center]]&lt;br /&gt;
=====Bubble Chart&amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/examples/interactive/bubble_chart&amp;lt;/ref&amp;gt;=====&lt;br /&gt;
The following code presents the example of area chart.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# http://code.google.com/apis/chart/interactive/docs/gallery/bubblechart.html&lt;br /&gt;
  def bubble_chart&lt;br /&gt;
&lt;br /&gt;
    data_table = GoogleVisualr::DataTable.new&lt;br /&gt;
    data_table.new_column('string', 'ID')&lt;br /&gt;
    data_table.new_column('number', 'Life Expectancy')&lt;br /&gt;
    data_table.new_column('number', 'Fertility Rate')&lt;br /&gt;
    data_table.new_column('string', 'Region')&lt;br /&gt;
    data_table.new_column('number', 'Population')&lt;br /&gt;
    data_table.add_rows( [&lt;br /&gt;
      ['CAN',    80.66,              1.67,      'North America',  33739900],&lt;br /&gt;
      ['DEU',    79.84,              1.36,      'Europe',         81902307],&lt;br /&gt;
      ['DNK',    78.6,               1.84,      'Europe',         5523095],&lt;br /&gt;
      ['EGY',    72.73,              2.78,      'Middle East',    79716203],&lt;br /&gt;
      ['GBR',    80.05,              2,         'Europe',         61801570],&lt;br /&gt;
      ['IRN',    72.49,              1.7,       'Middle East',    73137148],&lt;br /&gt;
      ['IRQ',    68.09,              4.77,      'Middle East',    31090763],&lt;br /&gt;
      ['ISR',    81.55,              2.96,      'Middle East',    7485600],&lt;br /&gt;
      ['RUS',    68.6,               1.54,      'Europe',         141850000],&lt;br /&gt;
      ['USA',    78.09,              2.05,      'North America',  307007000]&lt;br /&gt;
    ])&lt;br /&gt;
&lt;br /&gt;
    opts    = {&lt;br /&gt;
      :width =&amp;gt; 800, :height =&amp;gt; 500,&lt;br /&gt;
      :title =&amp;gt; 'Correlation between life expectancy, fertility rate and population of some world countries (2010)',&lt;br /&gt;
      :hAxis =&amp;gt; { :title =&amp;gt; 'Life Expectancy' },&lt;br /&gt;
      :vAxis =&amp;gt; { :title =&amp;gt; 'Fertility Rate'  },&lt;br /&gt;
      :bubble =&amp;gt; { :textStyle =&amp;gt; { :fontSize =&amp;gt; 11 } }&lt;br /&gt;
    }&lt;br /&gt;
    @chart = GoogleVisualr::Interactive::BubbleChart.new(data_table, opts)&lt;br /&gt;
&lt;br /&gt;
  end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The resulting chart looks like below.&lt;br /&gt;
[[File:BubbleChart.png|center]]&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
pie chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.pie(:data =&amp;gt; [20, 35, 45])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Piechart.png]]&lt;br /&gt;
&lt;br /&gt;
These usages come from http://googlecharts.rubyforge.org/. If you want to see more usages, go and visit this site.&lt;br /&gt;
&lt;br /&gt;
===gchartrb===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
===Circles===&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
This section describes where in Expertiza we can use these visualizations to provide a better user experience. &lt;br /&gt;
The 'Review Score' view of the assignments can be enhanced using these visualization.&lt;br /&gt;
&lt;br /&gt;
We can see by the image below that currently the scores views includes only a large table. From a user experience perspective having a more prioritized view of the scores would be beneficial. Having all the data available for the user to peruse in a table is informative, but when the user wants only to get a quick idea of how they did in an assignment, it would be helpful to have some sort of visualization.&lt;br /&gt;
&lt;br /&gt;
[[File:score_view.png.jpeg]]&lt;br /&gt;
&lt;br /&gt;
The above scoring which is in tabular form can be enhanced with charts.&lt;br /&gt;
&lt;br /&gt;
==Graphical Score Dashboard==&lt;br /&gt;
The scores page was augmented with bar graphs displaying the distributions of each column, as well as a circle icon for the average score for that column. This will allow for easily determining what the reviewers thought of the work, as well as what the range of scores given. The circle graphs with the averages provide a visual for the quality of the work in each of the categories.&lt;br /&gt;
&lt;br /&gt;
[[File:Mockup2.png]]&lt;br /&gt;
&lt;br /&gt;
==Reliability Metric==&lt;br /&gt;
Based on the uniformity of the review scores, we will compile a reliability metric. This metric encapsulates the level of agreement between the reviews, and should provide a quick at a glance notion of whether reviewers agree on the scoring for the particular assignment, or whether there is a high variance in the scores given. A good reliability score indicates that the grade given to the assignment by the reviewers is to be trusted, whereas a poor reliability score indicates that there was a high level of disagreement in the reviewers and the instructors should perhaps take a closer look at the participant's assignment.&lt;br /&gt;
This reliability score is computed from the standard deviation of the review scores. A standard deviation that's less than 10 will award a good reliability score. A standard deviation between 10 and 20 will award a medium reliability score, whereas a standard deviation greater than 20 will give a poor reliability score.&lt;br /&gt;
===Different Icon colors===&lt;br /&gt;
[[File:MockupG.png]]&lt;br /&gt;
&lt;br /&gt;
The color of the three bars Icon, and the number of filled bars is representative of the reliability of the reviews.&lt;br /&gt;
Take the case of the green sample icon in the image above, the reviews mostly all agree. Whereas in the following two images, the icon is yellow and red respectively to signify increasingly worrying levels of disparity in review scores.&lt;br /&gt;
[[File:MockupY.png]]&lt;br /&gt;
[[File:MockupR.png]]&lt;br /&gt;
&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015&amp;diff=96483</id>
		<title>CSC/ECE 517 Spring 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015&amp;diff=96483"/>
		<updated>2015-04-05T19:12:34Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Writing Assignment 1==&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 17 WL]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 5 ZX]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 6 TZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 4 RW]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 7 SA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 9 RA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 14 RI]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 1 DZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 20 HA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 3 RF]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 12 LS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 13 MA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 2 WA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 21 QW]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 23 MS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 10 GL]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 27 VC]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 22 SF]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 15 SH]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 18 AS]]&lt;br /&gt;
&lt;br /&gt;
==Writing Assignment 2==&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1502 wwj]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2014/oss E1508 MRS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1504 IMV]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1505 xzl]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1509 lds]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1510 FLP]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1506 SYZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss S1504 AAC]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1507 DG]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss M1502 GVJ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss M1503 EDT]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1503 RSA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1501 YWS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss S1501 OA]]&lt;br /&gt;
&lt;br /&gt;
==Final Project Design Document==&lt;br /&gt;
&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1526 MPRI]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 S1503 LWJZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 S1524 FSZZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 M1503 EDTS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1529 GLDS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1525 TIAA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1522 Visualization]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1527 SWAR]]&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015&amp;diff=96482</id>
		<title>CSC/ECE 517 Spring 2015</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015&amp;diff=96482"/>
		<updated>2015-04-05T19:12:19Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;==Writing Assignment 1==&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 17 WL]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 5 ZX]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 6 TZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 4 RW]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 7 SA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 9 RA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 14 RI]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 1 DZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 20 HA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 3 RF]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 12 LS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 13 MA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1a 2 WA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 21 QW]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 23 MS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 10 GL]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 27 VC]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 22 SF]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 15 SH]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/ch1b 18 AS]]&lt;br /&gt;
&lt;br /&gt;
==Writing Assignment 2==&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1502 wwj]]&lt;br /&gt;
*[[CSC/ECE 517 Fall 2014/oss E1508 MRS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1504 IMV]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1505 xzl]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1509 lds]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1510 FLP]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1506 SYZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss S1504 AAC]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1507 DG]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss M1502 GVJ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss M1503 EDT]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1503 RSA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss E1501 YWS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015/oss S1501 OA]]&lt;br /&gt;
&lt;br /&gt;
==Final Project Design Document==&lt;br /&gt;
&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1526 MPRI]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 S1503 LWJZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 S1524 FSZZ]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 M1503 EDTS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1529 GLDS]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1525 TIAA]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1522 VISU]]&lt;br /&gt;
*[[CSC/ECE 517 Spring 2015 E1527 SWAR]]&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96363</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96363"/>
		<updated>2015-04-01T03:09:01Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Detail Usages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
pie chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.pie(:data =&amp;gt; [20, 35, 45])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Piechart.png]]&lt;br /&gt;
&lt;br /&gt;
These usages come from http://googlecharts.rubyforge.org/. If you want to see more usages, go and visit this site.&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96361</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96361"/>
		<updated>2015-04-01T03:06:35Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Detail Usages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
pie chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.pie(:data =&amp;gt; [20, 35, 45])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Piechart.png]]&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Piechart.png&amp;diff=96359</id>
		<title>File:Piechart.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Piechart.png&amp;diff=96359"/>
		<updated>2015-04-01T03:06:03Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96355</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96355"/>
		<updated>2015-04-01T03:03:52Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Detail Usages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96353</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96353"/>
		<updated>2015-04-01T03:03:14Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Detail Usages */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a a wrapper around the Google Chart Tools&amp;lt;ref&amp;gt;https://developers.google.com/chart/&amp;lt;/ref&amp;gt; which allows users to create beautiful charts with just Ruby, instead of writing JavaScript if using the Google Chart Tools directly.&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&lt;br /&gt;
====Installing====&lt;br /&gt;
Installing GoogleVisualr is pretty simple. Just include the following gem in the Gemfile.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
gem &amp;quot;google_visualr&amp;quot;, &amp;quot;~&amp;gt; 2.1.0&amp;quot;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
And in the Rails layout, load Google Ajax API in the head tag, at the very top.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;script src='http://www.google.com/jsapi'&amp;gt;&amp;lt;/script&amp;gt;;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Work Flow====&lt;br /&gt;
*In your model or controller, write Ruby code to create your chart (e.g. Area Chart, Bar Chart, even Spark Lines etc).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Add Column Headers&lt;br /&gt;
  data_table.new_column('string', 'Year' )&lt;br /&gt;
  data_table.new_column('number', 'Sales')&lt;br /&gt;
  data_table.new_column('number', 'Expenses')&lt;br /&gt;
  # Add Rows and Values&lt;br /&gt;
  data_table.add_rows([&lt;br /&gt;
    ['2004', 1000, 400],&lt;br /&gt;
    ['2005', 1170, 460],&lt;br /&gt;
    ['2006', 660, 1120],&lt;br /&gt;
    ['2007', 1030, 540]&lt;br /&gt;
  ])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
*Configure your chart with any of the options as listed in Google Chart Tools' API Docs.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
option = { width: 400, height: 240, title: 'Company Performance' }&amp;lt;br/&amp;gt;&lt;br /&gt;
@chart = GoogleVisualr::Interactive::AreaChart.new(data_table, option)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*In your view, invoke a chart.to_js(div_id) method and that will magically generate and insert JavaScript into the final HTML output.&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;div id='chart'&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;%= render_chart @chart, 'chart' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
simple line chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Simplechart.png]]&lt;br /&gt;
bar chart:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [300, 100, 30, 200])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Barchart.png]]&lt;br /&gt;
&lt;br /&gt;
multiple bars chart&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.bar(:data =&amp;gt; [[300, 100, 30, 200], [100, 200, 300, 10]], :bar_colors =&amp;gt; ['FF0000', '00FF00'])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
[[File:Multbarschart.png]]&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Multbarschart.png&amp;diff=96351</id>
		<title>File:Multbarschart.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Multbarschart.png&amp;diff=96351"/>
		<updated>2015-04-01T03:02:54Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Barchart.png&amp;diff=96346</id>
		<title>File:Barchart.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Barchart.png&amp;diff=96346"/>
		<updated>2015-04-01T03:00:44Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Simplechart.png&amp;diff=96344</id>
		<title>File:Simplechart.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Simplechart.png&amp;diff=96344"/>
		<updated>2015-04-01T02:57:17Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: uploaded a new version of &amp;amp;quot;File:Simplechart.png&amp;amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=File:Simplechart.png&amp;diff=96343</id>
		<title>File:Simplechart.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=File:Simplechart.png&amp;diff=96343"/>
		<updated>2015-04-01T02:55:19Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96308</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96308"/>
		<updated>2015-04-01T02:26:03Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* GoogleVisualr */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr is a&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96306</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96306"/>
		<updated>2015-04-01T02:25:13Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts &amp;lt;ref&amp;gt;http://googlecharts.rubyforge.org/&amp;lt;/ref&amp;gt; and GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt;.  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt; is a&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96305</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96305"/>
		<updated>2015-04-01T02:24:14Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts (http://googlecharts.rubyforge.org/) and GoogleVisualr (http://googlevisualr.herokuapp.com/).  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt; is a&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96304</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96304"/>
		<updated>2015-04-01T02:23:57Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts (http://googlecharts.rubyforge.org/) and GoogleVisualr (http://googlevisualr.herokuapp.com/).  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt; is a&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;br /&gt;
==Reference==&lt;br /&gt;
&amp;lt;reference/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96298</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96298"/>
		<updated>2015-04-01T02:21:04Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* GoogleCharts */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts (http://googlecharts.rubyforge.org/) and GoogleVisualr (http://googlecharts.rubyforge.org/).  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
 GoogleVisualr &amp;lt;ref&amp;gt;http://googlevisualr.herokuapp.com/&amp;lt;/ref&amp;gt; is a&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
=====Installing=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Example in Ruby on Rails=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [1, 2, 3, 4, 5])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Basic Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
=====Detail Usages=====&lt;br /&gt;
----&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96288</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96288"/>
		<updated>2015-04-01T02:17:10Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Usage */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts (http://googlecharts.rubyforge.org/) and GoogleVisualr (http://googlecharts.rubyforge.org/).  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
====Installing====&lt;br /&gt;
&amp;lt;pre&amp;gt;gem install googlecharts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
====Example in Ruby on Rails====&lt;br /&gt;
'''Controller''':  &amp;lt;pre&amp;gt;@line_chart = Gchart.line(:data =&amp;gt; [0, 40, 10, 70, 20])&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''View''': &amp;lt;pre&amp;gt; &amp;lt;%= image_tag(@line_chart) %&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
====Basic Usages====&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
require ‘gchart’&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
Gchart.line(:size =&amp;gt; ‘200*200’,&lt;br /&gt;
:title =&amp;gt; “title”,&lt;br /&gt;
:bg =&amp;gt; ‘efefef’,&lt;br /&gt;
:legend =&amp;gt; &lt;br /&gt;
:data =&amp;gt; [1, 2, 3, 4, 5])&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
====Detail Usages====&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96276</id>
		<title>CSC/ECE 517 Spring 2015 E1522 Visualization</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015_E1522_Visualization&amp;diff=96276"/>
		<updated>2015-04-01T02:11:56Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* GoogleCharts */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt; Expertiza - Visualization &amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Project Description==&lt;br /&gt;
In this project, the data in Expertiza would be presented in a more convenient and instinct way.&lt;br /&gt;
&lt;br /&gt;
==Purpose==&lt;br /&gt;
&lt;br /&gt;
==Overview of Approach==&lt;br /&gt;
There are quite a few gems available to visualize data in Ruby on Rails, like Goolgecharts (http://googlecharts.rubyforge.org/) and GoogleVisualr (http://googlecharts.rubyforge.org/).  These gems makes use of Google Visualization API and wrap it to let users write ruby codes to present nice charts in their web pages instead of using Javascript.&lt;br /&gt;
===GoogleVisualr===&lt;br /&gt;
&lt;br /&gt;
===GoogleCharts===&lt;br /&gt;
Googlecharts is a ruby gem implements a wrapper for Google Chart API. It is fully tested using RSpec.&lt;br /&gt;
&lt;br /&gt;
===='''Usage'''====&lt;br /&gt;
&lt;br /&gt;
==Visualization in Expertiza==&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94303</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94303"/>
		<updated>2015-02-19T03:44:53Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Examples */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Simple Form aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of Simple Form is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from '''Formtastic&amp;lt;ref&amp;gt;https://github.com/justinfrench/formtastic&amp;lt;/ref&amp;gt;'''.&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to '''H5BP&amp;lt;ref&amp;gt;http://html5boilerplate.com&amp;lt;/ref&amp;gt;''' and  '''Grid System 960&amp;lt;ref&amp;gt;http://960.gs&amp;lt;/ref&amp;gt;''', Bootstrap is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form:install --bootstrap&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the Bootstrap assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
==Usage and Examples==&lt;br /&gt;
===A Simple Form and Bootstrap Sample===&lt;br /&gt;
A simple form and bootstrap sample application &amp;lt;ref&amp;gt;A simple form example http://simple-form-bootstrap.plataformatec.com.br/documentation&amp;lt;/ref&amp;gt; gives some insight into how to build a decent form with the help of simple form and bootstrap. &lt;br /&gt;
The code to create a form is listed below.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= simple_form_for @user_basic, url: create_basic_examples_url, as: 'user_basic'  do |f| %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :email, placeholder: 'Enter email' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :password, placeholder: 'Password' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :file, as: :file, wrapper: :vertical_file_input %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :active, wrapper: :vertical_boolean %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :choices, as: :check_boxes,&lt;br /&gt;
    collection: [&lt;br /&gt;
      'Option one is this and that—be sure to include why it\'s great',&lt;br /&gt;
      'Option two can be something else and selecting it will deselect option one'],&lt;br /&gt;
      wrapper: :vertical_radio_and_checkboxes %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :sex, as: :radio_buttons,&lt;br /&gt;
    collection: ['Male', 'Female'], wrapper: :vertical_radio_and_checkboxes %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.button :submit %&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In the code&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= f.input :email, placeholder: 'Enter email' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
a placeholder is created by passing it to the input method.&lt;br /&gt;
&lt;br /&gt;
In the code&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= f.input :file, as: :file, wrapper: :vertical_file_input %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
a wrapper is used to define the file format.&lt;br /&gt;
&lt;br /&gt;
We could also find that &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wrapper: :vertical_radio_and_checkboxes&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
goes twice in the code. To get rid of the duplicate wrappers, the &amp;lt;code&amp;gt;wrapper_mapping&amp;lt;/code&amp;gt; method could be used to define customized wrapper definition, as is shown below.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= simple_form_for @user_basic, url: create_basic_examples_url, as: 'user_basic',&lt;br /&gt;
  wrapper_mappings: {&lt;br /&gt;
    check_boxes: :vertical_radio_and_checkboxes,&lt;br /&gt;
    radio_buttons: :vertical_radio_and_checkboxes,&lt;br /&gt;
    file: :vertical_file_input,&lt;br /&gt;
    boolean: :vertical_boolean&lt;br /&gt;
  } do |f| %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :email, placeholder: 'Enter email' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :password, placeholder: 'Password' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :file, as: :file %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :active %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :choices, as: :check_boxes,&lt;br /&gt;
    collection: [&lt;br /&gt;
      'Option one is this and that—be sure to include why it\'s great',&lt;br /&gt;
      'Option two can be something else and selecting it will deselect option one'] %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :sex, as: :radio_buttons,&lt;br /&gt;
    collection: ['Male', 'Female'] %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.button :submit %&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then the code would become more DRY&amp;lt;ref&amp;gt;http://en.wikibooks.org/wiki/Ruby_on_Rails/Getting_Started/Don%C2%B4t_repeat_yourself&amp;lt;/ref&amp;gt;.&lt;br /&gt;
Finally the form generated by this Simple Form code and bootstrap looks like &lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot; style=&amp;quot;width: auto; margin-left: auto; margin-right: auto;&amp;quot;&amp;gt; [[File:basic_form_example.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot; style=&amp;quot;width: auto; margin-left: auto; margin-right: auto;&amp;quot;&amp;gt;Figure 1 The resulting form generated by Simple Form.&amp;lt;ref&amp;gt;http://simple-form-bootstrap.plataformatec.com.br/documentation&amp;lt;/ref&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94302</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94302"/>
		<updated>2015-02-19T03:41:30Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Simple Form aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of Simple Form is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from '''Formtastic&amp;lt;ref&amp;gt;https://github.com/justinfrench/formtastic&amp;lt;/ref&amp;gt;'''.&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to '''H5BP&amp;lt;ref&amp;gt;http://html5boilerplate.com&amp;lt;/ref&amp;gt;''' and  '''Grid System 960&amp;lt;ref&amp;gt;http://960.gs&amp;lt;/ref&amp;gt;''', Bootstrap is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form:install --bootstrap&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the Bootstrap assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
==Examples==&lt;br /&gt;
===A Simple Form and Bootstrap Sample===&lt;br /&gt;
A simple form and bootstrap sample application &amp;lt;ref&amp;gt;A simple form example http://simple-form-bootstrap.plataformatec.com.br/documentation&amp;lt;/ref&amp;gt; gives some insight into how to build a decent form with the help of simple form and bootstrap. &lt;br /&gt;
The code to create a form is listed below.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= simple_form_for @user_basic, url: create_basic_examples_url, as: 'user_basic'  do |f| %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :email, placeholder: 'Enter email' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :password, placeholder: 'Password' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :file, as: :file, wrapper: :vertical_file_input %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :active, wrapper: :vertical_boolean %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :choices, as: :check_boxes,&lt;br /&gt;
    collection: [&lt;br /&gt;
      'Option one is this and that—be sure to include why it\'s great',&lt;br /&gt;
      'Option two can be something else and selecting it will deselect option one'],&lt;br /&gt;
      wrapper: :vertical_radio_and_checkboxes %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :sex, as: :radio_buttons,&lt;br /&gt;
    collection: ['Male', 'Female'], wrapper: :vertical_radio_and_checkboxes %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.button :submit %&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In the code&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= f.input :email, placeholder: 'Enter email' %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
a placeholder is created by passing it to the input method.&lt;br /&gt;
&lt;br /&gt;
In the code&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= f.input :file, as: :file, wrapper: :vertical_file_input %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
a wrapper is used to define the file format.&lt;br /&gt;
&lt;br /&gt;
We could also find that &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
wrapper: :vertical_radio_and_checkboxes&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
goes twice in the code. To get rid of the duplicate wrappers, the &amp;lt;code&amp;gt;wrapper_mapping&amp;lt;/code&amp;gt; method could be used to define customized wrapper definition, as is shown below.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;%= simple_form_for @user_basic, url: create_basic_examples_url, as: 'user_basic',&lt;br /&gt;
  wrapper_mappings: {&lt;br /&gt;
    check_boxes: :vertical_radio_and_checkboxes,&lt;br /&gt;
    radio_buttons: :vertical_radio_and_checkboxes,&lt;br /&gt;
    file: :vertical_file_input,&lt;br /&gt;
    boolean: :vertical_boolean&lt;br /&gt;
  } do |f| %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :email, placeholder: 'Enter email' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :password, placeholder: 'Password' %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :file, as: :file %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :active %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :choices, as: :check_boxes,&lt;br /&gt;
    collection: [&lt;br /&gt;
      'Option one is this and that—be sure to include why it\'s great',&lt;br /&gt;
      'Option two can be something else and selecting it will deselect option one'] %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.input :sex, as: :radio_buttons,&lt;br /&gt;
    collection: ['Male', 'Female'] %&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;%= f.button :submit %&amp;gt;&lt;br /&gt;
&amp;lt;% end %&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then the code would become more DRY&amp;lt;ref&amp;gt;http://en.wikibooks.org/wiki/Ruby_on_Rails/Getting_Started/Don%C2%B4t_repeat_yourself&amp;lt;/ref&amp;gt;.&lt;br /&gt;
Finally the form generated by this Simple Form code and bootstrap looks like &lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot; style=&amp;quot;width: auto; margin-left: auto; margin-right: auto;&amp;quot;&amp;gt; [[File:basic_form_example.png]]&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;center&amp;quot; style=&amp;quot;width: auto; margin-left: auto; margin-right: auto;&amp;quot;&amp;gt;Figure 1 The resulting form generated by Simple Form.&amp;lt;ref&amp;gt;http://simple-form-bootstrap.plataformatec.com.br/documentation&amp;lt;/ref&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94267</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94267"/>
		<updated>2015-02-18T22:02:22Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Simple Form aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of Simple Form is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from '''Formtastic&amp;lt;ref&amp;gt;https://github.com/justinfrench/formtastic&amp;lt;/ref&amp;gt;'''.&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to '''H5BP&amp;lt;ref&amp;gt;http://html5boilerplate.com&amp;lt;/ref&amp;gt;''' and  '''Grid System 960&amp;lt;ref&amp;gt;http://960.gs&amp;lt;/ref&amp;gt;''', Bootstrap is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form:install --bootstrap&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the Bootstrap assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
===Usage===&lt;br /&gt;
&lt;br /&gt;
==Other Examples==&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94266</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94266"/>
		<updated>2015-02-18T22:01:41Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Simple Form aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of Simple Form is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from '''Formtastic&amp;lt;ref&amp;gt;https://github.com/justinfrench/formtastic&amp;lt;/ref&amp;gt;'''.&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to '''H5BP&amp;lt;ref&amp;gt;http://html5boilerplate.com&amp;lt;/ref&amp;gt;''' and  '''Grid System 960&amp;lt;ref&amp;gt;http://960.gs&amp;lt;/ref&amp;gt;''', Bootstrap is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form:install --bootstrap&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the Bootstrap assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
==Other Examples==&lt;br /&gt;
&lt;br /&gt;
==Conclusion==&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94265</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94265"/>
		<updated>2015-02-18T22:00:53Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Simple Form aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of Simple Form is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from '''Formtastic&amp;lt;ref&amp;gt;https://github.com/justinfrench/formtastic&amp;lt;/ref&amp;gt;'''.&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to '''H5BP&amp;lt;ref&amp;gt;http://html5boilerplate.com&amp;lt;/ref&amp;gt;''' and  '''Grid System 960&amp;lt;ref&amp;gt;http://960.gs&amp;lt;/ref&amp;gt;''', Bootstrap is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form:install --bootstrap&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the Bootstrap assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94264</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94264"/>
		<updated>2015-02-18T21:57:29Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Simple Form aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of Simple Form is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to '''H5BP&amp;lt;ref&amp;gt;http://html5boilerplate.com&amp;lt;/ref&amp;gt;''' and  '''Grid System 960&amp;lt;ref&amp;gt;http://960.gs&amp;lt;/ref&amp;gt;''', Bootstrap is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form:install --bootstrap&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the Bootstrap assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94263</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94263"/>
		<updated>2015-02-18T21:56:09Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Simple Form aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of Simple Form is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Started ==&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to '''H5BP&amp;lt;ref&amp;gt;http://html5boilerplate.com&amp;lt;/ref&amp;gt;''' and  '''Grid System 960&amp;lt;ref&amp;gt;http://960.gs&amp;lt;/ref&amp;gt;''', Bootstrap is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form:install --bootstrap&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the Bootstrap assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
&amp;lt;references/&amp;gt;&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94262</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94262"/>
		<updated>2015-02-18T21:48:22Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;''' is a very useful gem which allows you to create forms for your Rails application. It also integrates very easily with [http://getbootstrap.com/ Bootstrap].&lt;br /&gt;
.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Rails forms made easy &amp;lt;br /&amp;gt;'''Simple Form''' aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of '''Simple Form''' is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Start ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to [http://html5boilerplate.com H5BP] and [http://960.gs 960 Grid System], Bootstrap  is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;--&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bootstrap&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the [http://getbootstrap.com/ Bootstrap] assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94261</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94261"/>
		<updated>2015-02-18T21:44:34Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Simple Form&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Simple Form &amp;lt;ref&amp;gt;https://github.com/plataformatec/simple_form&amp;lt;/ref&amp;gt;'''is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Rails forms made easy &amp;lt;br /&amp;gt;'''Simple Form''' aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of '''Simple Form''' is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Start ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to [http://html5boilerplate.com H5BP] and [http://960.gs 960 Grid System], [http://getbootstrap.com/ Bootstrap] is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;--&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bootstrap&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the [http://getbootstrap.com/ Bootstrap] assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94260</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94260"/>
		<updated>2015-02-18T21:43:06Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;font size=&amp;quot;6&amp;quot;&amp;gt;&amp;lt;b&amp;gt;Devise&amp;lt;/b&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Devise &amp;lt;ref&amp;gt;https://github.com/plataformatec/devise&amp;lt;/ref&amp;gt;''' is a Rails gem used for authenticating and managing users. &lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found [https://docs.google.com/a/ncsu.edu/document/d/1Ay5OOUkcLMC-FH61fAm3cNvB3Uyk2hJ09vHnRgqwL-k/edit here].&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Rails forms made easy &amp;lt;br /&amp;gt;'''Simple Form''' aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of '''Simple Form''' is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Start ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to [http://html5boilerplate.com H5BP] and [http://960.gs 960 Grid System], [http://getbootstrap.com/ Bootstrap] is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;--&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bootstrap&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the [http://getbootstrap.com/ Bootstrap] assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94259</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94259"/>
		<updated>2015-02-18T21:42:12Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Simple Form */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Rails forms made easy &amp;lt;br /&amp;gt;'''Simple Form''' aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of '''Simple Form''' is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Start ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to [http://html5boilerplate.com H5BP] and [http://960.gs 960 Grid System], [http://getbootstrap.com/ Bootstrap] is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;--&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bootstrap&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the [http://getbootstrap.com/ Bootstrap] assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94258</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94258"/>
		<updated>2015-02-18T21:41:01Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* Installation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;1 Introduction&lt;br /&gt;
     1.1 Background&lt;br /&gt;
 2 Getting Start&lt;br /&gt;
     2.1 Installation&lt;br /&gt;
     2.2 Bootstrap&lt;br /&gt;
     2.3 Usage&lt;br /&gt;
 3 Example applications&lt;br /&gt;
 &lt;br /&gt;
 4 Other Rails forms framework&lt;br /&gt;
     4.1 Formtastic&lt;br /&gt;
 5 Conclusion&lt;br /&gt;
 6 References&lt;br /&gt;
 &amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Rails forms made easy &amp;lt;br /&amp;gt;'''Simple Form''' aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of '''Simple Form''' is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Start ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem install simple_form&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;gem 'simple_form'&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;bundle install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;pre&amp;gt;rails generate simple_form install&amp;lt;/pre&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to [http://html5boilerplate.com H5BP] and [http://960.gs 960 Grid System], [http://getbootstrap.com/ Bootstrap] is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;--&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bootstrap&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the [http://getbootstrap.com/ Bootstrap] assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94253</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94253"/>
		<updated>2015-02-18T21:20:59Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: /* CSC/ECE 517 Spring 2015/ch1b 22 JC */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;1 Introduction&lt;br /&gt;
     1.1 Background&lt;br /&gt;
 2 Getting Start&lt;br /&gt;
     2.1 Installation&lt;br /&gt;
     2.2 Bootstrap&lt;br /&gt;
     2.3 Usage&lt;br /&gt;
 3 Example applications&lt;br /&gt;
 &lt;br /&gt;
 4 Other Rails forms framework&lt;br /&gt;
     4.1 Formtastic&lt;br /&gt;
 5 Conclusion&lt;br /&gt;
 6 References&lt;br /&gt;
 &amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Rails forms made easy &amp;lt;br /&amp;gt;'''Simple Form''' aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of '''Simple Form''' is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Start ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;gem install simple_form&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;gem &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;str&amp;quot;&amp;gt;'simple_form'&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bundle install&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to [http://html5boilerplate.com H5BP] and [http://960.gs 960 Grid System], [http://getbootstrap.com/ Bootstrap] is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;--&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bootstrap&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the [http://getbootstrap.com/ Bootstrap] assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
	<entry>
		<id>https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94252</id>
		<title>CSC/ECE 517 Spring 2015/ch1b 22 SF</title>
		<link rel="alternate" type="text/html" href="https://wiki.expertiza.ncsu.edu/index.php?title=CSC/ECE_517_Spring_2015/ch1b_22_SF&amp;diff=94252"/>
		<updated>2015-02-18T21:20:44Z</updated>

		<summary type="html">&lt;p&gt;Njiang4: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== CSC/ECE 517 Spring 2015/ch1b 22 JC ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Simple Form ==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Simple form is a Rails gem used for easily creating Rails forms.&lt;br /&gt;
&lt;br /&gt;
The topic write up for this page can be found here.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;code&amp;gt;1 Introduction&lt;br /&gt;
     1.1 Background&lt;br /&gt;
 2 Getting Start&lt;br /&gt;
     2.1 Installation&lt;br /&gt;
     2.2 Bootstrap&lt;br /&gt;
     2.3 Usage&lt;br /&gt;
 3 Example applications&lt;br /&gt;
 &lt;br /&gt;
 4 Other Rails forms framework&lt;br /&gt;
     4.1 Formtastic&lt;br /&gt;
 5 Conclusion&lt;br /&gt;
 6 References&lt;br /&gt;
 &amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Introduction ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Background ===&lt;br /&gt;
&lt;br /&gt;
Rails forms made easy &amp;lt;br /&amp;gt;'''Simple Form''' aims to be as flexible as possible while helping you with powerful components to create your forms . The basic goal of '''Simple Form''' is to not touch your way of defining the layout, letting you find the better design for your eyes. Most of the DSL was inherited from Formtastic.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Getting Start ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Installation ===&lt;br /&gt;
&lt;br /&gt;
You can use the following code to install simple_form:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;gem install simple_form&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
But I recommend you to use the following way: &amp;lt;br /&amp;gt; Add the following code to your Gemfile:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;gem &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;str&amp;quot;&amp;gt;'simple_form'&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
And in your Rails application root directory, run the following command:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bundle install&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
Run the following code to generate the simple_form into your app:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Work with Bootstrap ===&lt;br /&gt;
&lt;br /&gt;
Similar to [http://html5boilerplate.com H5BP] and [http://960.gs 960 Grid System], [http://getbootstrap.com/ Bootstrap] is a simple and very popular front-end framework.&lt;br /&gt;
&lt;br /&gt;
With the following code while installing Simple Form, you can integrate Simple Form to Bootstrap&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 # &amp;lt;code class=&amp;quot;language-ruby&amp;quot;&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;rails generate simple_form&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;:&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;install &amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pun&amp;quot;&amp;gt;--&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;pln&amp;quot;&amp;gt;bootstrap&amp;lt;/span&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
You have to be sure that you added a copy of the [http://getbootstrap.com/ Bootstrap] assets on your application.&lt;br /&gt;
&lt;br /&gt;
For more information see the generator output, out example application code and the live example app.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;md-section-divider&amp;quot;&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== References ==&lt;br /&gt;
# https://github.com/plataformatec/simple_form&lt;br /&gt;
# http://getbootstrap.com/&lt;br /&gt;
# https://github.com/justinfrench/formtastic&lt;br /&gt;
#&lt;/div&gt;</summary>
		<author><name>Njiang4</name></author>
	</entry>
</feed>