The author reiterated his view that why investing for dividend and interest income doom to fail. His feeling is if someone aims to double his net worth might, he at least has a chance to succeed and retain his capital or even make a good profit out of it.
However, trying to double the money return requires a lot of hard work.
Quick link to The Battle for Investment Survival
by Gerald M. Loeb
My First Mac and Virtual Box Experience
I am officially a Mac convert.
Still learning how to survive on one mouse button and use these fn, control, option and command keys. But so far so good. My MBP experience is absolutely positive.
Before the purchase, I was slightly worried about if I may pay too much for a fine GUI. After last few days of hand-on experience, I think, as many MBP users has attested, the premium is well worth it.
I, in particular, appreciate the BSD root of Mac OSX. Whenever I cannot use the Mac OSX GUI to get thing done, I can always fall back to command line alternatives.
Vista is a staggering failure of MS Corp in every sense (I have used Vista for a year). As Paul Graham puts it, Microsoft has ceased to be relevant. They still have market share, but it is a market share going to erode fast, under the attacks of Sun, Linux and FOSS. The unwillingness to waste any more time on Vista is my prime motivation to switch.
The very first application I have downloaded is the VirtualBox. Basically within seconds I can start a new virtual instance of Ubuntu 8.04 beta. By default I can only ssh into the box via NAT. Will need to do some research to see how to get bridging done in Mac OSX.
The second application I tried is, not surprisingly, QuickSliver, an utility that warranted an hour of Google Tech Talk.
Militant Materialism

Came across this co-ed article on IHT, by David Brooks. By coincidence I found this blog post , by Jean Kazez, soon afterwards, which is related to belief in God as well.
I do not think I have much nice thing to say about David Brooks. Let’s say I am usually unimpressed by the arguments put foward by David in Shields and Brooks on PBS. Not because he is a Right-wing political pundit per se, but because what his reasoning and arguments are usually not very grounded. I still watched the PBS program because what he has to say, it seems to me, a good indicators of the current conservative sentiments and stances on issues.
But this article, which first appeared in NYT in case you may not know, articulated the issue of the current wave of militant materialism against the Religion rather well. Two outstanding icons in this movement are Richard Dawkin and Christopher Hitchens.
My primary reservation about Richard and Christopher’s position is: If we apply reduction blindly, and dismiss phenomena in the field of spirituality rather offhandedly, then go on to brand people on opposite side as delusional or stupid, then it is not a scientific approach to study a problem.
God exists or not? I like to compare this question to the study of nature of light back in the 17th century. Issac Newton believed light is particle but Descarte thought it is wave. Do you think one side has a particular right to brand the other side delusional and stupid? We should always keep in our mind the limit and boundary of human knowledge and intelligence.
Jean’s article has given his view on the reasoning and response from both side of the argument. I agree with the fact he pointed out: both sides are so ready to throw in stock arguments.
Overall, between the Militant Materialism and the Militant Evangelicals, there is no dialog going on. Just publicity grabbers grabbing for publicity.
A proof of the lack of depth: do take a look at how Christopher Hitchens debated his view against Kenneth Miller in the Templeton Conversation.
I was mildly offended when Christopher probed Kenneth’s religious background. (Out of the blue, he bought up the question, “Incidentally, are you a Christian?”, to Kenneth) While it is an effective debate technique, i.e. to highlight one’s board identity in order to imply the innate bias, and hence invalidity, in his/her reasoning. It is not right in this debate especially when the opponent is sincere and candid in the discussion.
Ant
http://youtube.com/watch?v=R07_JFfnFnY
@ 35:00 – ant does not smell right.
@ 37: – simple AI nernon
The Importance of Being Nosy (Nosetests, Really)
Unit testing
One of a few important lessons I learn from Java development is the importance of unit test. It is of course not a silver bullet to the software reliability/quality problem, but the consequence not adopting it can only be more dire.
I used only JUnit to implement unit tests in Java (Since JUnit is “good enough”, I never explore the alternative framework TestNG.). Actually, problems in writing unit tests usually have very little to do with the frameworks themselves, but more with:
A. The legacy code base you want to test against. For example, if the existing code base design is not modular enough, you have to go through some refactoring process to make unit testing possible. It is not the kind of luxury we can afford very often.
B. Mock objects. EasyMock has made mocking a dependency easier, but maintaining the mock object codes still requires considerable effort.
Unit testing and Python
I think unit testing is even more important for Python programmers.
Since everything happens in runtime for Python, errors in your scripts, no matter syntactical or logical, will not be caught until you actually execute the line of code where the bug lives.
On top of it, a majority of commercial/in-house software contains so many features. The sheer number of possible combination of the execution pathways means thorough manual testing is simply unattainable, if not unrealistic.
If at the end of the day, a production issue in your python software arises and it turns out to be “incorrect indentation”, the managers and users will look down on you pretty hard (“Did you really test it?”). Unit test + coverage tools can help us to avoid these kind of situation.
Besides, unit tests can be used to safeguard corner cases and exceptional conditions. For financial applications, one of those commonly-seen mistakes is that a program fails to perform properly when a certain event (e.g. rollover) happens on a public holiday. With unit testing, we can subject the relevant codes to different combination of date and instruments, so we can make sure it will, for instance, calculate accrual correctly no matter what.
Comparing Java, I find it easier to do unit testing in Python because, with Python’s “Duck Typing” capability, we do not have to worry about maintaining mock objects at all. Whenever you need to mimic a dependency’s behavior, just write a dummy class with just enough attributes/methods the testee expects. End of story.
No more record and play APIs, as in EasyMock.
Nosetests makes it easy
So, you can understand why I am so glad to find nose. Nosetests is, in a nutshell, a unit test discovery tool. It can traverse down a python source code directory and pick up classes that extends unittest.Testcase, doc test, and any classes/methods that follow the default naming convention. I can now mix any testing styles depending on the task at hand.
I usually use the following parameters with nosetests:
—verbosity=3 —with-doctest -s —exe
“—exe” is necessary because in cygwin, my primary development environment, py files are usually set to be “executable”.
Feedback
Do you have any tips and idea on unit testing/software quality assurance to share? Feel free.