<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Economics International Blog &#187; Yahoo Pipes</title>
	<atom:link href="http://www.econinternational.com/blog/tag/yahoo-pipes/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.econinternational.com/blog</link>
	<description>An informal look at economics, finance, and statistics</description>
	<lastBuildDate>Mon, 07 Jun 2010 11:31:15 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Piping economics throughout the Twitterverse</title>
		<link>http://www.econinternational.com/blog/2010/02/26/piping-economics-throughout-the-twitterverse/</link>
		<comments>http://www.econinternational.com/blog/2010/02/26/piping-economics-throughout-the-twitterverse/#comments</comments>
		<pubDate>Fri, 26 Feb 2010 18:07:25 +0000</pubDate>
		<dc:creator>eric.fruits</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[economics]]></category>
		<category><![CDATA[Twitter]]></category>
		<category><![CDATA[Yahoo Pipes]]></category>

		<guid isPermaLink="false">http://www.econinternational.com/blog/?p=540</guid>
		<description><![CDATA[I am on a crusade to make Twitter a place for useful economic information and informative economics discussion.  That goal is partially accomplished by following economists doing interesting and relevant research and subscribing to economics Twitter lists.  The problem is that so many tweets&#8212;even those by economists&#8212;have nothing to do with economics. I recently rediscovered [...]]]></description>
			<content:encoded><![CDATA[<p>I am on a crusade to make Twitter a place for useful economic information and informative economics discussion.  That goal is partially accomplished by <a href="http://www.econinternational.com/blog/2009/03/13/twitter-follow-friday-economists-on-twitter/" target="_blank">following economists doing interesting and relevant research</a> and subscribing to <a href="http://twitter.com/ericfruits/economics" target="_blank">economics Twitter lists</a>.  The problem is that so many tweets&#8212;even those by economists&#8212;have nothing to do with economics.</p>
<p>I recently rediscovered <a href="http://pipes.yahoo.com/pipes/" target="_blank">Yahoo Pipes</a> and found that it can interact with Twitter in a way that does not require any coding on my part and does not require that the application be served on my own <a href="http://www.econinternational.com/" target="_blank">website</a>.</p>
<p>The result is <a href="http://twitter.com/TweetEcon" target="_blank">TweetEcon</a>, an experimental retweeting economics Twitterbot.  Here is a sample of the tweets TweetEcon has retweeted:</p>
<p><a href="http://www.econinternational.com/blog/wp-content/uploads/2010/02/00_tweetecon.jpg"><img class="aligncenter size-full wp-image-541" title="00_tweetecon" src="http://www.econinternational.com/blog/wp-content/uploads/2010/02/00_tweetecon.jpg" alt="" width="480" /></a></p>
<h2>How to build your own retweeting Twitterbot</h2>
<p>1.  Get a <a href="http://pipes.yahoo.com/pipes/" target="_blank">Yahoo Pipes</a> account and create a new pipe.</p>
<p>2.  Get the tweets to be retweeted.  Under <strong>Sources</strong>, grab <strong>Fetch Feed</strong>.  Go to <a href="http://search.twitter.com/" target="_blank">Twitter Search</a> and enter a search term, such as <em>economics</em>.   On the results page, click the link that says <a onclick="pageTracker._trackPageview('/exit/rss/economics')" href="http://search.twitter.com/search.atom?lang=en&amp;q=economics">Feed  for  this query</a>.  This will take you to the RSS feed.  Notice that  there are a lot of worthless tweets that use the word <em>economics</em>.   That is why the next step is necessary.</p>
<p><a href="http://www.econinternational.com/blog/wp-content/uploads/2010/02/01_fetch_feed.jpg"><img class="aligncenter size-full wp-image-542" title="01_fetch_feed" src="http://www.econinternational.com/blog/wp-content/uploads/2010/02/01_fetch_feed.jpg" alt="" width="252" height="140" /></a></p>
<p>3. Filter the tweets retrieved.  Under <strong>Operators</strong>, grab <strong>Filter</strong>.</p>
<p>First, filter out any retweets.  This serves two purposes: (a) it prevents retweet looping in which the pipe retweets its own tweets, and (b) most retweets are editorial rather than informative.  The swear words are blocked for obvious reasons.  Also, a huge portion of economics tweets say something like &#8220;My boyfriend&#8217;s cousin just lost his job at Best Buy. This economy sucks!&#8221;  Also another huge portion of tweets are from economics students griping about having to wake up at 9:00 a.m. so they can make it to their 10:15 a.m. class, which is why school related terms are blocked.</p>
<p>Unfortunately, tweets with #hashtags have a massive noise-to-signal ratio.  Here is one example:</p>
<blockquote><p><a href="http://twitter.com/lolvincitomnia/statuses/9663674112" target="_blank">RINO Marco Rubio speech  demanding amnesty for illegals http://youtu.be/3xIgN51XxD4 #teaparty #economy @gopleader #gop #tcot</a></p></blockquote>
<p>See, no economics in the tweet, but this twit decided to use the <a href="http://search.twitter.com/search?q=&amp;ands=&amp;phrase=&amp;ors=&amp;nots=&amp;tag=economy&amp;lang=en&amp;from=&amp;to=&amp;ref=&amp;near=&amp;within=15&amp;units=mi&amp;since=&amp;until=&amp;rpp=50" target="_blank">#economy</a> hashtag.</p>
<p>The most important filter is the filter that keeps only those tweets that have a link in it.  Tweets without links tend to provide observations or opinions, rather than useful information.  I decided that I will only retweet posts that have a link.</p>
<p>The filter is probably where most of the future tweaking will be.</p>
<p><a href="http://www.econinternational.com/blog/wp-content/uploads/2010/02/02_filter.jpg"><img class="aligncenter size-full wp-image-543" title="02_filter" src="http://www.econinternational.com/blog/wp-content/uploads/2010/02/02_filter.jpg" alt="" width="415" height="363" /></a></p>
<p>4. Form the retweet.  Under <strong>Operators</strong>, grab <strong>Loop</strong>.  The first field puts the author&#8217;s Twitter user name at the beginning of what will be my retweet.  The second field is a single space.  The third field is the tweet that is being retweeted.</p>
<p><a href="http://www.econinternational.com/blog/wp-content/uploads/2010/02/03_loop.jpg"><img class="aligncenter size-full wp-image-544" title="03_loop" src="http://www.econinternational.com/blog/wp-content/uploads/2010/02/03_loop.jpg" alt="" width="409" height="211" /></a></p>
<p>5.  Form the retweet, part 2.  Under <strong>Operators</strong>, grab <strong>Regex</strong>. This step replaces the Twitter username URL (e.g., <a href="http://twitter.com/ericfruits" target="_blank">http://twitter.com/ericfruits</a>) with the username used by Twitter (e.g. <a href="http://twitter.com/ericfruits" target="_blank">@ericfruits</a>) and adds &#8220;RT&#8221; in front.  Note, that the &#8220;RT @username&#8221; must go at the beginning of the tweet.  Otherwise, the tweet may be too long and cut off the RT.  If that happens, you run the risk of getting into a retweet loop.</p>
<p><a href="http://www.econinternational.com/blog/wp-content/uploads/2010/02/04_regex.jpg"><img class="aligncenter size-full wp-image-545" title="04_regex" src="http://www.econinternational.com/blog/wp-content/uploads/2010/02/04_regex.jpg" alt="" width="480" /></a></p>
<p>6.  (Optional) Sort the retweets from most recent to oldest. Under <strong>Operators</strong>, grab <strong>Sort</strong>.</p>
<p><a href="http://www.econinternational.com/blog/wp-content/uploads/2010/02/05_sort.jpg"><img class="aligncenter size-full wp-image-546" title="05_sort" src="http://www.econinternational.com/blog/wp-content/uploads/2010/02/05_sort.jpg" alt="" width="314" height="73" /> </a></p>
<p>7.  Test the pipe.  You may get some error messages (especially those that end in &#8220;420&#8243;).  Do not worry.  That means that Twitter and Yahoo Pipes are having a temporary spat.  Wait a few minutes and try again.  If it still does not work, save the pipe, go back to the <strong>My Pipes</strong> page, then click on the pipe and/or click on the RSS feed for the pipe.  This step will drive you crazy because you will not know if you have done something wrong.</p>
<p>8.  Tweet the pipe&#8217;s results.  Go to <strong>My Pipes</strong>, click on the pipe, then click on <a href="http://pipes.yahoo.com/pipes/pipe.run?_id=dda2aefdd22484dba1a488d907278023&amp;_render=rss">Get  as RSS</a>.  Now that you have the RSS, you can use <a href="http://twitterfeed.com/" target="_blank">Twitterfeed</a> and/or <a href="http://feedburner.google.com/" target="_blank">Feedburner</a> to convert the RSS output to tweets.  Twitterfeed is fairly self-explanatory.  To have Feedburner tweet the RSS, click on <strong>Publicize</strong>, then click on <strong>Socialize</strong> and follow the steps.</p>
<p>I use both Twitterfeed and Feedburner.  Because of the time and tweeting limits of both services, there is no real overlap of tweets.  For example, my pipe retrieves approximately 50 tweets an hour.  Twitterfeed will send out a maximum of 10 tweets an hour and Feedburner sends out a maximum of 16 tweets an hour (maybe).  So far, Twitterfeed is a much more reliable tweeter than Feedburner.</p>
<p>Happy pipe-tweeting!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.econinternational.com/blog/2010/02/26/piping-economics-throughout-the-twitterverse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
