<?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>Alessio Sclocco &#187; Information theory</title>
	<atom:link href="http://alessio.sclocco.eu/tag/information-theory/feed/" rel="self" type="application/rss+xml" />
	<link>http://alessio.sclocco.eu</link>
	<description>who I am and what I&#039;m doing</description>
	<lastBuildDate>Sun, 11 Dec 2011 17:59:55 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Information theory analyzer</title>
		<link>http://alessio.sclocco.eu/information-theory-analyzer/</link>
		<comments>http://alessio.sclocco.eu/information-theory-analyzer/#comments</comments>
		<pubDate>Mon, 24 Aug 2009 19:49:59 +0000</pubDate>
		<dc:creator>Alessio Sclocco</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Cpp]]></category>
		<category><![CDATA[Information theory]]></category>
		<category><![CDATA[University]]></category>

		<guid isPermaLink="false">http://alessio.sclocco.eu/?p=140</guid>
		<description><![CDATA[Hello :) I&#8217;ve taken an exam those summer called &#8220;Information theory&#8221; and as a project I&#8217;ve developed, with the help of Alfredo Aiello, a program for evaluating entropy (simple, joint and conditional) and mutual information of random variables (and subset of them) from a sample set. Like every other time I want to share the [...]]]></description>
			<content:encoded><![CDATA[<p>Hello :)</p>
<p>I&#8217;ve taken an exam those summer called &#8220;<a title="Information theory" href="http://en.wikipedia.org/wiki/Information_theory">Information theory</a>&#8221; and as a project I&#8217;ve developed, with the help of Alfredo Aiello, a program for evaluating entropy (simple, joint and conditional) and mutual information of random variables (and subset of them) from a sample set.</p>
<p>Like every other time I want to share the code (that is licensed with GNU General Public License 3.0) with the whole world, so this is a <a title="ITA" href="http://alessio.sclocco.eu/wp-content/uploads/2009/08/ITA.zip">zip file</a> containing all the code.<br />
There isn&#8217;t a makefile right now but you can easily find a way to compile it, the only external dependencies is my <a title="ArgumentList" href="http://alessio.sclocco.eu/argumentlist-01/">ArgumentList</a> library.</p>
<p>After compiling it you can use it on command line just tiping:</p>
<pre>./ITA &lt;[-e] | [-j] | [-c] | [-m]&gt; -n &lt;null_char&gt; &lt;set_file&gt; &lt;input_file&gt; &lt;output_file&gt;</pre>
<p>Obviously you have to call your binary :)</p>
<p>The first parameter is for the operation wanted (-e for entropy, -j for joint entropy, -c for conditional entropy and -m for mutual information), the second is for setting the null char of the sample set and last three ones are filename.<br />
The first of them (set_file) permits you to control which variable of the sample set is in which subset, I know I can be a little too enigmatic but I&#8217;ll provide an example later; the second (input_file)  is the file which contains the sample set and the third (output_file) is where do you want the output will be written.</p>
<p>The sample set format is really sample, is a text file where the columns are the variable and the rows are the samples, something like that:</p>
<pre>1 0 n 1
n 2 n n
a 0 2 2
2 c 1 2</pre>
<p>This is the description of a sample set with 4 samples and 4 variables.<br />
The format for the set_file is really simple too, again a text file where the first number is the length of first subset and all the others are the indexes (starting from 0) of the columns in the subset.</p>
<p>Let&#8217;s for example evaluate the conditional entropy between those two subset of the previously given sample set:</p>
<p>X = {0, 2, 3}<br />
Y = {1}</p>
<p>Then we&#8217;ll have to write a file (let&#8217;s call it example.set) like this one:</p>
<pre>3 0 2 3 1</pre>
<p>And, if our sample set is called example.txt, call the program in that way:</p>
<pre>./ITA -c -n n example.set example.txt out.txt</pre>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://alessio.sclocco.eu/information-theory-analyzer/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

