<?xml version="1.0" encoding="utf-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	>
<channel>
	<title>Comments on: Dynamic Stat Graphs in Rails</title>
	<atom:link href="http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/</link>
	<description>A goal is a dream with a deadline.</description>
	<pubDate>Wed, 10 Mar 2010 01:13:25 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7.1</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-211703</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Wed, 09 Sep 2009 21:23:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-211703</guid>
		<description>Hady, nothing top of mind -- the screenshot was custom built for that application.</description>
		<content:encoded><![CDATA[<p>Hady, nothing top of mind &#8212; the screenshot was custom built for that application.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Hady A.</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-211682</link>
		<dc:creator>Hady A.</dc:creator>
		<pubDate>Wed, 09 Sep 2009 17:20:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-211682</guid>
		<description>Great tutorial! back at work we've been looking for a nice source of how-to regarding Gruff, and thanks to you we've been able to visulaize our stats system instead of a table with so much boring numbers :)

I do have a question though, I really like the screenshot, the backend template really love it, simple and to the point =D if it's possible you could point me out to somewhere I could find something similar.</description>
		<content:encoded><![CDATA[<p>Great tutorial! back at work we&#8217;ve been looking for a nice source of how-to regarding Gruff, and thanks to you we&#8217;ve been able to visulaize our stats system instead of a table with so much boring numbers :)</p>
<p>I do have a question though, I really like the screenshot, the backend template really love it, simple and to the point =D if it&#8217;s possible you could point me out to somewhere I could find something similar.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Alex</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-149257</link>
		<dc:creator>Alex</dc:creator>
		<pubDate>Wed, 26 Nov 2008 21:52:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-149257</guid>
		<description>Excellent tutorial, was struggling to display the graph on the fly.</description>
		<content:encoded><![CDATA[<p>Excellent tutorial, was struggling to display the graph on the fly.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Scott</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-103105</link>
		<dc:creator>Scott</dc:creator>
		<pubDate>Fri, 09 May 2008 23:00:27 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-103105</guid>
		<description>Just wanted to say thank you. This was very helpful in explaining things - especially how to pull the keys out dynamically for the hash.</description>
		<content:encoded><![CDATA[<p>Just wanted to say thank you. This was very helpful in explaining things - especially how to pull the keys out dynamically for the hash.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-100989</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Sat, 12 Jan 2008 19:01:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-100989</guid>
		<description>Thanks for the tip Tim.. And indeed, scruffy is an awesome package. I built my '&lt;a href="http://www.igvita.com/2006/12/11/visual-database-explorer-in-ruby/" rel="nofollow"&gt;Visual Database Explorer&lt;/a&gt;' with it, and it worked just great.</description>
		<content:encoded><![CDATA[<p>Thanks for the tip Tim.. And indeed, scruffy is an awesome package. I built my &#8216;<a href="http://www.igvita.com/2006/12/11/visual-database-explorer-in-ruby/" rel="nofollow">Visual Database Explorer</a>&#8216; with it, and it worked just great.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tim waters</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-100919</link>
		<dc:creator>tim waters</dc:creator>
		<pubDate>Tue, 08 Jan 2008 21:03:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-100919</guid>
		<description>this is a bug with gruff.  From what i recall, it occurs with every odd row (I was using stacked bar graph).
There was a fix online to fix it, and it may have been patched now but Gruff still gives inaccurate stacked bar graphs so now I use Scruffy which blows the socks off Gruff.
http://scruffy.rubyforge.org/</description>
		<content:encoded><![CDATA[<p>this is a bug with gruff.  From what i recall, it occurs with every odd row (I was using stacked bar graph).<br />
There was a fix online to fix it, and it may have been patched now but Gruff still gives inaccurate stacked bar graphs so now I use Scruffy which blows the socks off Gruff.<br />
<a href="http://scruffy.rubyforge.org/" rel="nofollow">http://scruffy.rubyforge.org/</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-100707</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Thu, 27 Dec 2007 04:57:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-100707</guid>
		<description>Andrew, I've never ran into that problem before. Have you validated your SQL queries? Looking at the Ruby code, I can't see why this problem would come up...</description>
		<content:encoded><![CDATA[<p>Andrew, I&#8217;ve never ran into that problem before. Have you validated your SQL queries? Looking at the Ruby code, I can&#8217;t see why this problem would come up&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andrew</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-98767</link>
		<dc:creator>Andrew</dc:creator>
		<pubDate>Sun, 16 Dec 2007 12:35:50 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-98767</guid>
		<description>Hi Illya. It seems that when more than 5 different data points exist (e.g. 2006-07,  2006-08,  2006-09,  2006-10,  2006-11,  2006-12), the graph messes up. The data starts scattering randomly across the graph.

Has that been your case as well, and do you know of a fix for that issue?</description>
		<content:encoded><![CDATA[<p>Hi Illya. It seems that when more than 5 different data points exist (e.g. 2006-07,  2006-08,  2006-09,  2006-10,  2006-11,  2006-12), the graph messes up. The data starts scattering randomly across the graph.</p>
<p>Has that been your case as well, and do you know of a fix for that issue?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ilya Grigorik</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-86217</link>
		<dc:creator>Ilya Grigorik</dc:creator>
		<pubDate>Wed, 14 Nov 2007 03:07:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-86217</guid>
		<description>Bene, a simple way would be to first create a hash or an array of 365 items and map each entry to '0'. Then, simply iterate throughout the array and change any non-zero values to their proper counts. 

You might want look at 'srtftime' method, it'll help you convert any date into a 0...365 numeral.</description>
		<content:encoded><![CDATA[<p>Bene, a simple way would be to first create a hash or an array of 365 items and map each entry to &#8216;0&#8242;. Then, simply iterate throughout the array and change any non-zero values to their proper counts. </p>
<p>You might want look at &#8217;srtftime&#8217; method, it&#8217;ll help you convert any date into a 0&#8230;365 numeral.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bene</title>
		<link>http://www.igvita.com/2007/01/05/dynamic-stat-graphs-in-rails/comment-page-1/#comment-85917</link>
		<dc:creator>Bene</dc:creator>
		<pubDate>Tue, 13 Nov 2007 16:46:23 +0000</pubDate>
		<guid isPermaLink="false">http://www.igvita.com/blog/2007/01/05/dynamic-stat-graphs-in-rails/#comment-85917</guid>
		<description>Ilya, I have a question about your approach. I am a rails newbie and too weak to find it our myself.

I want to use Gruff to draw a bar chart of order subtotals per day for the last 365 days. Even on days with zero orders, these should be included with no bar in the graph, so the width.

How would I have to change above code to draw a "365 days in the past" canvas, and then assign the subtotal values for the days where they apply, or 0 for days without orders.

I know it's probably very easy to do in Ruby / Rails, but I  am used to messy PHP and don't want to inject that messiness into my Ruby code. 

Lazy, I know ;-) but I tried for a few hours now with no success.</description>
		<content:encoded><![CDATA[<p>Ilya, I have a question about your approach. I am a rails newbie and too weak to find it our myself.</p>
<p>I want to use Gruff to draw a bar chart of order subtotals per day for the last 365 days. Even on days with zero orders, these should be included with no bar in the graph, so the width.</p>
<p>How would I have to change above code to draw a &#8220;365 days in the past&#8221; canvas, and then assign the subtotal values for the days where they apply, or 0 for days without orders.</p>
<p>I know it&#8217;s probably very easy to do in Ruby / Rails, but I  am used to messy PHP and don&#8217;t want to inject that messiness into my Ruby code. </p>
<p>Lazy, I know ;-) but I tried for a few hours now with no success.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
