Thursday, June 07, 2007

Freebasic


An easy-to-use programming language is an invaluable tool for quantitative social scientists. I have learned several programming languages including C/C++, Java, Python, Pascal. My favorite language right now is FreeBasic (http://www.freebasic.net/). It is highly compatible with the once widely used QBasic and is 100% free. There are several editors that can be used with FreeBasic on Windows, including the one I am using, FbEdit (http://www.radasm.com/fbedit/). The picture on the left shows how to debug a FreeBasic program using Insight, a frontend of GNU debugging tool, GDB.


Sunday, June 03, 2007

Editing and comparing huge text files

I need to work on several huge text files, each being around 30M in size. The work involves cleaning them and comparing to each other. I have worked with several pretty good text editors before, some are free while others are commercial. For this particular work, I tried ultraedit, emeditor, vedit, madedit, and multiedit. For text comparison, I tried beyond compare and ultracompare. Overall, I would say that the winner is multiedit, for several reasons. First of all, even though all the editors I tested can handle large files, the process is not painless. Most editors show a significant slowdown after loading the files, even on my core 2 duo machine with 2 GB memory. Multiedit does not have this problem. The 30 MB file loads instantly and can easily scroll to anywhere in the file without delays. Second, most editors have very limited file comparison functions built-in, and is not suitable for the work I have at hand. I tried ultracompare, but it did not work in the way it is supposed to, and I gave it up after trying for several times (not a very patient man). Beyond compare delivers good results, then I realized that multiedit has a copy of beyond compare built-in!

The price for multiedit is a bit steep. When most other editors cost around $50 or less, it costs three times of that price ($149). That is probably why it is not used as widely as it could have been...

Friday, June 01, 2007

Best Linux Distro

I began using Linux in 2000, when I was a graduate student at UCLA. Since I have tried various distros including SuSE (open SuSE), RedHat (Fedora), Mandrake, Turbolinux, Debian, Slackware. I even bought a copy of a now discontinuted distro named "libranet". I settled on OpenSuSE for the past several years until I discovered Ubuntu. I have been running Ubuntu 7.04 on my desktop for more than a month and it has been a very pleasant experience so far.

The next distro I want to try is PCLinuxOS. It looks very nice and (from various reviewers) it runs very fast. I am going to install it once I have a new machine. Maybe at that time, I can have a good answer about which is, between Ubuntu and PCLinuxOS, the best Linux distro.

Sunday, May 06, 2007

Drawing maps using Stata

Don't need expensive specialized GIS anymore, just Stata.

http://www.stata.com/support/faqs/graphics/tmap.html

Saturday, April 21, 2007

A good cross-platform text editor

I use both Linux and Windows and have been searching for a good cross-platform text editor for a long time. Now this small piece software called "MadEdit" seems to be very promising. It is cross-platform, unicode enabled, free, and open source. Check it out at:

http://madedit.sourceforge.net/

Sunday, April 15, 2007

A good new book on Monte Carlo methods

Title: Simulation and Monte Carlo: With applications in finance and MCMC
Author: J. S. Dagpunar
Publisher: Wiley

This new book seems really cool and I will try to remember to buy it next time I visit US.

http://as.wiley.com/WileyCDA/WileyTitle/productCd-0470854952.html

Wednesday, April 11, 2007

Maple, a good tool to teach maximum likelihood method

The new Maple has very convenient tool built-in to demonstrate the process of maximum likelihood estimation in an intuitive way. Unlike software like Stata, SAS, or Matlab, where the computation is done numerically under the surface, Maple solves the problem analytically with the whole process showing up on the screen. This way, students can clearly see what is happening: how to get log likelihood function, how to solve it , what the Hessian matrix looks like, etc.

Very good teaching tool.

Wednesday, March 21, 2007

Multiple imputation with growth modeling

Several days ago, a new user-contributed Stata module "MIM" appears in the Stata software repository. This module can automate the process of combing estimates from multiply imputed data sets and calculating confidence intervals for a wide array of Stata estimation commands, including "XTMIXED". This means that the complete process of imputation, estimation, and post-estimation can be done without leaving Stata.

Saturday, March 10, 2007

Multiple imputation with longitudinal data

Have been working with Sarah on revising our comparative paper. One problem we need to solve in this revision is the presence of large amount of missing values. I use "ICE", a user contributed module in Stata to do the imputation. Unfortunately, the built-in estimation procedures does not include "XTMIXED" or "GLLAMM". I have to import the imputed data sets into Mplus and do the estimation there.

Counter