<?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: Chart Against The X Factor</title>
	<atom:link href="http://bitplane.net/2009/12/bash-for-xmas-number-one/feed/" rel="self" type="application/rss+xml" />
	<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/</link>
	<description>Rants, ramblings, free software</description>
	<lastBuildDate>Wed, 08 Feb 2012 21:14:59 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Gaz Davidson</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-161</link>
		<dc:creator>Gaz Davidson</dc:creator>
		<pubDate>Thu, 17 Dec 2009 12:36:36 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-161</guid>
		<description>Yes, the raw data is currently available here:

http://dump.bitplane.net/ratm/data.dat

Sometime after Sunday I&#039;ll move the latest graphs back to my blog along with the results, the scripts used to generate them and maybe even a bit of analysis. Watch this space!

If you can think of any cool things to do with the data then please just go ahead and use it, post me a link and I&#039;ll link back to it :)</description>
		<content:encoded><![CDATA[<p>Yes, the raw data is currently available here:</p>
<p><a href="http://dump.bitplane.net/ratm/data.dat" rel="nofollow">http://dump.bitplane.net/ratm/data.dat</a></p>
<p>Sometime after Sunday I&#8217;ll move the latest graphs back to my blog along with the results, the scripts used to generate them and maybe even a bit of analysis. Watch this space!</p>
<p>If you can think of any cool things to do with the data then please just go ahead and use it, post me a link and I&#8217;ll link back to it <img src='http://bitplane.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: nick rose</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-160</link>
		<dc:creator>nick rose</dc:creator>
		<pubDate>Thu, 17 Dec 2009 12:05:48 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-160</guid>
		<description>Hi, is there any plans to publish the full details once the campaign is over? Id be really interested to see all the data collated.</description>
		<content:encoded><![CDATA[<p>Hi, is there any plans to publish the full details once the campaign is over? Id be really interested to see all the data collated.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gaz Davidson</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-159</link>
		<dc:creator>Gaz Davidson</dc:creator>
		<pubDate>Tue, 15 Dec 2009 03:43:11 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-159</guid>
		<description>It should be working again now Dimitri, it was caused by a change to the group&#039;s name, I&#039;ve fixed the regexp like so:

&lt;pre lang=&quot;bash&quot;&gt;
# extract user count from the file
usercount=`sed -n -e &quot;s/.*&gt;[0-9]* of \(.*\) members&lt;.*/\1/p&quot; temp.html`
&lt;/pre&gt;</description>
		<content:encoded><![CDATA[<p>It should be working again now Dimitri, it was caused by a change to the group&#8217;s name, I&#8217;ve fixed the regexp like so:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># extract user count from the file</span>
<span style="color: #007800;">usercount</span>=<span style="color: #000000; font-weight: bold;">`</span><span style="color: #c20cb9; font-weight: bold;">sed</span> <span style="color: #660033;">-n</span> <span style="color: #660033;">-e</span> <span style="color: #ff0000;">&quot;s/.*&gt;[0-9]* of \(.*\) members&lt;.*/\1/p&quot;</span> temp.html<span style="color: #000000; font-weight: bold;">`</span></pre></div></div>

]]></content:encoded>
	</item>
	<item>
		<title>By: Dimitri</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-158</link>
		<dc:creator>Dimitri</dc:creator>
		<pubDate>Mon, 14 Dec 2009 19:55:19 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-158</guid>
		<description>Hey Gaz, 

Great work on the script, and thanks for sharing the code. Just noticed, the index page doesn&#039;t seem to load normally anymore (firefox tries to download it instead of interpreting the html). Any idea why? 

Thanks,
Dimitri</description>
		<content:encoded><![CDATA[<p>Hey Gaz, </p>
<p>Great work on the script, and thanks for sharing the code. Just noticed, the index page doesn&#8217;t seem to load normally anymore (firefox tries to download it instead of interpreting the html). Any idea why? </p>
<p>Thanks,<br />
Dimitri</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: nick rose</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-157</link>
		<dc:creator>nick rose</dc:creator>
		<pubDate>Mon, 14 Dec 2009 11:25:42 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-157</guid>
		<description>Excellent graph :D We&#039;re an internet machine!!!</description>
		<content:encoded><![CDATA[<p>Excellent graph <img src='http://bitplane.net/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' />  We&#8217;re an internet machine!!!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Interpolated list class for Python &#8211; bitplane.net</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-154</link>
		<dc:creator>Interpolated list class for Python &#8211; bitplane.net</dc:creator>
		<pubDate>Sat, 12 Dec 2009 03:25:31 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-154</guid>
		<description>[...] messing with Python to output some better graphs for my Facebook group scraper I stumbled upon an interesting problem. What happens if you have missing samples, or want to change [...]</description>
		<content:encoded><![CDATA[<p>[...] messing with Python to output some better graphs for my Facebook group scraper I stumbled upon an interesting problem. What happens if you have missing samples, or want to change [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: James French</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-152</link>
		<dc:creator>James French</dc:creator>
		<pubDate>Fri, 11 Dec 2009 18:22:03 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-152</guid>
		<description>This is too cool Gaz. I&#039;m impressed. I think I&#039;m going to learn a thing or two from these scripts - cheers!

James</description>
		<content:encoded><![CDATA[<p>This is too cool Gaz. I&#8217;m impressed. I think I&#8217;m going to learn a thing or two from these scripts &#8211; cheers!</p>
<p>James</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave Holden</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-151</link>
		<dc:creator>Dave Holden</dc:creator>
		<pubDate>Fri, 11 Dec 2009 13:30:08 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-151</guid>
		<description>Many thanks!</description>
		<content:encoded><![CDATA[<p>Many thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gaz Davidson</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-150</link>
		<dc:creator>Gaz Davidson</dc:creator>
		<pubDate>Fri, 11 Dec 2009 11:57:53 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-150</guid>
		<description>It assumes that there are similar volumes of users joining at the same time each day and predicts based on how many have joined so far today compared to the same time over the last three days:

&lt;pre lang=&quot;python&quot;&gt;

secs_today = int(total_range) % 86400

# start time was 12am on Sunday, there are 86400 secs in a day
for i in range( int(start), int(start) + int(day_count+1) * 86400, 86400):
    days.append(
                 # tuple: day name
                 (strftime(&#039;%b%d&#039;, gmtime(i) ),
                 # total that day
                 data[i+86400] - data[i],
                 # amount at the same time on that day
                 data[i+secs_today] - data[i])
                )

# take the average values of the last three full days
tot     = 0.0
partial = 0.0
for i in days[-4:-1]:
    tot = tot + i[1]
    partial = partial + i[2]

factor = tot / partial

# make a prediction
prediction = days[-1][2] * factor
&lt;/pre&gt;

&quot;data&quot; is my InterpoList class which does linear interpolation to fill in the gaps between measurements, you can get it here:
http://svn.bitplane.net/misc/trunk/py/InterpoList.py</description>
		<content:encoded><![CDATA[<p>It assumes that there are similar volumes of users joining at the same time each day and predicts based on how many have joined so far today compared to the same time over the last three days:</p>

<div class="wp_syntax"><div class="code"><pre class="python" style="font-family:monospace;">&nbsp;
secs_today = <span style="color: #008000;">int</span><span style="color: black;">&#40;</span>total_range<span style="color: black;">&#41;</span> <span style="color: #66cc66;">%</span> <span style="color: #ff4500;">86400</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># start time was 12am on Sunday, there are 86400 secs in a day</span>
<span style="color: #ff7700;font-weight:bold;">for</span> i <span style="color: #ff7700;font-weight:bold;">in</span> <span style="color: #008000;">range</span><span style="color: black;">&#40;</span> <span style="color: #008000;">int</span><span style="color: black;">&#40;</span>start<span style="color: black;">&#41;</span>, <span style="color: #008000;">int</span><span style="color: black;">&#40;</span>start<span style="color: black;">&#41;</span> + <span style="color: #008000;">int</span><span style="color: black;">&#40;</span>day_count+<span style="color: #ff4500;">1</span><span style="color: black;">&#41;</span> <span style="color: #66cc66;">*</span> <span style="color: #ff4500;">86400</span>, <span style="color: #ff4500;">86400</span><span style="color: black;">&#41;</span>:
    days.<span style="color: black;">append</span><span style="color: black;">&#40;</span>
                 <span style="color: #808080; font-style: italic;"># tuple: day name</span>
                 <span style="color: black;">&#40;</span>strftime<span style="color: black;">&#40;</span><span style="color: #483d8b;">'%b%d'</span>, gmtime<span style="color: black;">&#40;</span>i<span style="color: black;">&#41;</span> <span style="color: black;">&#41;</span>,
                 <span style="color: #808080; font-style: italic;"># total that day</span>
                 data<span style="color: black;">&#91;</span>i+<span style="color: #ff4500;">86400</span><span style="color: black;">&#93;</span> - data<span style="color: black;">&#91;</span>i<span style="color: black;">&#93;</span>,
                 <span style="color: #808080; font-style: italic;"># amount at the same time on that day</span>
                 data<span style="color: black;">&#91;</span>i+secs_today<span style="color: black;">&#93;</span> - data<span style="color: black;">&#91;</span>i<span style="color: black;">&#93;</span><span style="color: black;">&#41;</span>
                <span style="color: black;">&#41;</span>
&nbsp;
<span style="color: #808080; font-style: italic;"># take the average values of the last three full days</span>
tot     = <span style="color: #ff4500;">0.0</span>
partial = <span style="color: #ff4500;">0.0</span>
<span style="color: #ff7700;font-weight:bold;">for</span> i <span style="color: #ff7700;font-weight:bold;">in</span> days<span style="color: black;">&#91;</span>-<span style="color: #ff4500;">4</span>:-<span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span>:
    tot = tot + i<span style="color: black;">&#91;</span><span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span>
    partial = partial + i<span style="color: black;">&#91;</span><span style="color: #ff4500;">2</span><span style="color: black;">&#93;</span>
&nbsp;
factor = tot / partial
&nbsp;
<span style="color: #808080; font-style: italic;"># make a prediction</span>
prediction = days<span style="color: black;">&#91;</span>-<span style="color: #ff4500;">1</span><span style="color: black;">&#93;</span><span style="color: black;">&#91;</span><span style="color: #ff4500;">2</span><span style="color: black;">&#93;</span> <span style="color: #66cc66;">*</span> factor</pre></div></div>

<p>&#8220;data&#8221; is my InterpoList class which does linear interpolation to fill in the gaps between measurements, you can get it here:<br />
<a href="http://svn.bitplane.net/misc/trunk/py/InterpoList.py" rel="nofollow">http://svn.bitplane.net/misc/trunk/py/InterpoList.py</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dave Holden</title>
		<link>http://bitplane.net/2009/12/bash-for-xmas-number-one/comment-page-1/#comment-149</link>
		<dc:creator>Dave Holden</dc:creator>
		<pubDate>Fri, 11 Dec 2009 11:48:38 +0000</pubDate>
		<guid isPermaLink="false">http://bitplane.net/?p=342#comment-149</guid>
		<description>The new versions of your graphs are awesome! Thanks for creating them.

I&#039;m curious about the number of members being predicted today, the curve seems to go up steeply. It&#039;s predicting 70399 new members now. Where do these figures come from please?</description>
		<content:encoded><![CDATA[<p>The new versions of your graphs are awesome! Thanks for creating them.</p>
<p>I&#8217;m curious about the number of members being predicted today, the curve seems to go up steeply. It&#8217;s predicting 70399 new members now. Where do these figures come from please?</p>
]]></content:encoded>
	</item>
</channel>
</rss>

