Skip to content

Instantly share code, notes, and snippets.

@kaspergrubbe
Created December 25, 2013 12:27
Show Gist options
  • Save kaspergrubbe/8122827 to your computer and use it in GitHub Desktop.
Save kaspergrubbe/8122827 to your computer and use it in GitHub Desktop.
table width=500 height=100
tr
- @dates[:range].each do |date|
td width=( (100.0 / @dates[:range].size).to_f.to_s + "%" ) style="background: #000000;" #width
= (date[:traffic] / @dates[:max]).to_i #height
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment