Friday, October 27, 2006

Variable filenames in Matlab Save

In Matlab, a command such as
fname = 'foo';
save fname var1

will store var1 in fname.mat as against the desired foo.mat

A solution to this would be to issues the following two commands
foos = sprintf('save %s var1','foo');
eval(foos)

will save var1 in foo.mat

Thursday, October 26, 2006

Mosquito

I finally had a week long vacation on account of diwali and ramzan holidays. As I was expecting to spend a significant part of my vacation travelling, I took with me two of the lastest additions to my small library - The Argumentative Indian by Armartya Sen and The City of Joy by Dominique Lapierre. The former is a series of essays by the venerable nobel laureate on the argumentative aspects of Indian culture and history while the latter is touching description of the great city of Calcutta.

I started off with Sen's book, but after I finished reading the first two essays, I realised it was too serious a book to read while on vacation. So I set it aside for a cold rainy day and took up the other book which I am, well, yet to put down! A very engrossing account of the life of the downtrodden in a Calcutta slum. I had earlier read another book - Freedom at Midnight by the same author and with City of Joy, Lapierre has entered my list of favorite authors.

I leave u with an extract from the book, about an Indian mosquito:

Indian mosquitoes have as a distinguishing characteristic the fact that they are minute, make very little noise, and tease you endlessly before making up their minds to bite. The effect is a torture of anticipation which, if it were not Indian, would almost certainly be Chinese.

How true!