Author Archives: Thomas Cokelaer

GIT tutorial

I finally decided to use GIT for one of my new project. I know this sounds odd given that everybody nowadays seems to use it… Having used SVN for a while the transition should be smooth though. There are a … Continue reading

Posted in Software development | Tagged | Leave a comment

Entropy and information

In everyday parlance, entropy refers to the inevitable deterioration of a system (including a society). As you may remember from a physics course, there is a far more formal definition that originates from thermodynamics. I’ll spare you the equation but … Continue reading

Posted in Notes | Tagged | Leave a comment

latex: same footnote but different reference places (with hyperlink)

I had the following issue with LaTeX: I first created a footnote. Later on in the text I wanted to refer to the same footnote. The issue is that the footnote contains a hyperlink. After reading the few pages from … Continue reading

Posted in Computer Science | Tagged | 11 Comments

Python: ValueError: unknown locale: UTF-8

When installing bioservices (a python package) using pip or easy_install, I got this error Mac OS X 10.7 – Lion: ValueError: unknown locale: UTF-8ValueError: unknown locale: UTF-8 Although the installation is successful, the error will appear as soon as we … Continue reading

Posted in Uncategorized | Leave a comment

Using valgrind to debug R programs

If you want to debug your R program because of a segmentation fault or memory leak, you can use valgrind as follows in a shell: R -d "valgrind –leak-check=full –show-reachable=yes" -f your_script.RR -d "valgrind –leak-check=full –show-reachable=yes" -f your_script.R

Posted in R | Tagged , | Leave a comment

ipython error

If you get this kind of error when starting ipython: /Library/Frameworks/Python.framework/Versions/7.3/lib/python2.7/site-packages/kernmagic/__init__.py in activate(ip, *args) 14 continue 15 magic_name = name[len(’magic_’):] —> 16 ip.shell.define_magic(magic_name, getattr(mymagics, name)) 17 18 def activate_aliases(ip, *args):   AttributeError: ‘TerminalInteractiveShell’ object has no attribute ‘shell’/Library/Frameworks/Python.framework/Versions/7.3/lib/python2.7/site-packages/kernmagic/__init__.py in activate(ip, … Continue reading

Posted in Python | Tagged | Leave a comment

Accessing Life Science Web Services from Python

In a previous post, I started to discuss about Web Services in Life Science and what a maze it is to navigate between them. Some Web Services provides Python code to access to their databases but not all of them. … Continue reading

Posted in biology, Life Science | Tagged , , , , | Leave a comment

LSF cluster commands

From Wikipedia, Load Sharing Facility (or simply LSF) is a commercial computer software, job scheduler sold by Platform Computing. It can be used to execute batch jobs on networked Unix. Here is a summary of some commands I’ve been using. … Continue reading

Posted in Computer Science | Tagged | Leave a comment

Python: pip installation

References: http://www.pip-installer.org/en/latest/installing.html The installation of pip depends on your system. For instance under ubuntu it is as easy as sudo apt-get install python-pipsudo apt-get install python-pip Another way to install it if you are familiar with virtualenv tool consists in … Continue reading

Posted in Linux, Python | Tagged , | Leave a comment

R warnings when starting rpy2 and installation

On Fedora 15 When I start rpy2 using this command import rpy2 from rpy2 import robjectsimport rpy2 from rpy2 import robjects I was getting these annoying warnings, which do not appear when starting a pure R session: During startup – … Continue reading

Posted in Computer Science | Tagged , | 4 Comments