Monthly Archives: August 2011

Fitting distribution by combing R and Python

The following example illustrates how to use R package with Python by using the Rpy2 package. This problem solve in this example is to fit a normal distribution on some data samples.   from rpy2.robjects import r from rpy2.robjects.packages import … Continue reading

Posted in Python | Tagged , , | Leave a comment

Profiling in Python

Lot of information is available in the Python documentation website: http://docs.python.org/library/profile.html . However, here is a small snapshot of how to use it : Let us say you have a function call test(). First you need to run it: import … Continue reading

Posted in Python | Tagged | Leave a comment

vim: replace the windows ^M character under Linux

Within VIM, there is a way to replace all the return carriage from Windows (that appear as ^M) by replacing them with the Linux version: % s/^M/\r/g% s/^M/\r/g When \r stands for the return carriage in Linux (not \n as … Continue reading

Posted in Computer Science | Tagged | Leave a comment

SVN: How to revert (roll back) to a previous version ?

One reason to use SVN tool is to be able to revert to a previous version. How do we do that ? Imagine that the latest version (the one on the HEAD) is not what you want anymore, but that … Continue reading

Posted in Computer Science | Tagged | Leave a comment

running PHP from Command Line Shell

If you want to test some PHP code without using the browser interface, you can create a script to use command line shell as follows. Let us call this script scripting.php. Under Linux, create this file with the php extension … Continue reading

Posted in Computer Science | Tagged | Leave a comment

R: how to use command line arguments from R scripts

If you want to script R with arguments, you can type (under a Linux shell): R –no-restore –no-save –args 10 < script.RR –no-restore –no-save –args 10 < script.R where –args is a list of arguments that you want to use … Continue reading

Posted in Computer Science | Tagged | Leave a comment

Thunderbird hangs forever when “Copying message to Sent folder”

I set up a new account under Thunderbird with an IMAP in-going and SMTP out-going. All mails and folders are correclty imported from the server. I received new mails can delete them (it is updated on the server). So everything … Continue reading

Posted in Internet related, Uncategorized | Tagged , | 77 Comments

Fedora 15 : Firefox drag and drop does not work

The solution is to install gtk2-engines package: sudo yum install gtk2-engines.i686sudo yum install gtk2-engines.i686 Please follow and like us:

Posted in Linux | Tagged , | Leave a comment

Fedora 15: firefox bookmarks subfolder icons missing

You need first to install dconf-editor if not already done: sudo yum install dconf-editorsudo yum install dconf-editor launch it and go to org->gnome->desktop->interfaceorg->gnome->desktop->interface set menus-have-icons=true. Please follow and like us:

Posted in Linux | Tagged , | Leave a comment

How to setup PHP under fedora

The following solution to install Apache, MySQL and PHP was checked under Fedora 15 distribution. First, you need to install the relevant packages: su #for root login, enter password when prompted yum install mysql-server service mysqld start mysqladmin -u root … Continue reading

Posted in Linux | Tagged , | Leave a comment