October 5, 2009
Posted by xenocoder under Ferret
Leave a Comment
As part of my current work I have been playing around with model output with PMEL’s Ferret software. One of the things that I wanted to do was to make a seasonal climatology from a time subset (e.g. quarterly averages centered on Feb, May, Aug, Oct for 1998-2007). If the data is defined using a standard calendar it’s fairly straightforward and is laid out in the Ferret FAQ.
However, this data is defined with a constant NOLEAP calendar, so we have to do a little more work. I was able to dig up some information on the Ferret mailing list archives where Jaison Kurian gave a nice example for making a custom modulo grid for a 360_DAY calendar. I was able to take his example and reshape it into what I needed for the NOLEAP data.
yes? define axis/t="16-FEB-0001:00":"16-OCT-0001":3\
yes? let lsrat9807clim = lsrat9807[gt=noleapseas@MOD]
yes? list lsratclim[X=180,Y=30]
16-FEB / 1: 0.1108
18-MAY / 2: 0.1388
17-AUG / 3: 0.1026
16-NOV / 4: 0.0559
which checks out with a manual average spot check. Nice.
September 29, 2009
I made a successful upgrade to Snow Leopard recently on my Macbook Pro, and while 99% of it was positive, there are some strange things which just “don’t work” anymore.
One example is the ability to browse Windows shares and shared printers on windows computers. This worked fine on Leopard, but is no longer working with SL.
In looking around I found a work around which, while not elegant, kind of makes sense and I’ll use for now. Basically what was happening was that SL can see the Samba share, but can’t resolve the IP address. So by adding in the computer name and IP address to /etc/hosts you can fix the problem.
Hint taken from MacWindows.com
February 15, 2009
Just an update on the Matlab situation. I recently did renew my maintenance fees, but dropped support for the optimization, mapping, and GARCH toolboxes as I never used this. The only thing I ever used the mapping toolbox for was calcultating distances, and that got busted at some point. The free m_map software is a far superior toolbox, and did I mention it was free?
Part of the decision was that all of the analysis for the last chapter of my dissertation was done in R. Some data mining was done with Python, oceanographic transects/profiles in Ocean Data View and maps in GMT, but all analysis was done in R. This was a revelation to me, mostly due to the change in not having to write an m-script full of loops. I know that some of this is due to my bad habits in Matlab (not using the vector operations and writing loops instead) but there are so many convenience functions in R that just do what I want, and I think that this reflects a change to a more statistically demanding anaylsis style that Matlab really just isn’t built for.
This isn’t to say that one is better than the other, but with the cost and difficulty in getting Matlab up and running on new machines, R is definitely more than a viable option, and a joy to work with.
February 15, 2009
Posted by xenocoder under Uncategorized
| Tags: osx
Leave a Comment
Just wanted to add that I received the Macbook Pro back from Apple repair in less than 10 days. Nicely done! The computer is snappier than ever and all artifacts of the display not waking up after sleeping are gone!
On another positive note, I was successful in restoring the Super Duper backup in 20 minutes. Incredible software!
January 22, 2009
Posted by xenocoder under Computers
, Mac OS X
| Tags: apple
Leave a Comment
So out of the blue the display stopped working on my 15″ Macbook Pro. The computer would come out of sleep, but no display, nothing. Total blackness. I was also unable to get anything on the external display as well. After a bit of research everyone seemed to agree (from what I’d read) that it was the logic board, and that since it was out of warranty it would cost a pretty penny. I decided to try my luck and give Apple Care a call. To their credit, they at least talked to me even though I was out of warranty. Their “fix” was for me to go into the nearest Apple store and get service there. I was also quoted at $1100 for a new display. Now, I also explained the entire situation (computer is on, can get to it in target mode, just no displays), and he felt it was a motherboard problem. That made no sense to me.
I gave up for a bit to get some work done, and then late in the evening I decided to look on the net one more time. Lo and behold something interesting appeared. Evidently this nVidia thing where you get a black screen after waking up from sleep is common. So common that they are reimbursing any repairs that involved the nVidia cards on these MacBooks.
So I printed that out and took it with me to the “Genius” bar. It must be common because they had a special device to check for the nVidia failure. And there it was… So the repair is free, but I’m out the laptop for 10 days+. The plus being related to something strange. We were all finished when the “genius” asked me for my username and password “So they can do tests and stuff”. Well, there was no way that I was giving my username and password out, and that was pretty much the only admin account on there. Since I had just made a backup with Super Duper I had them wipe the drive, but I thought the whole thing was bizarre. Can’t they do the tests from a disk in single user mode?
At any rate, I’m happy that it’s a free repair, but confused why the Apple Care guy didn’t at least acknowledge that this could be the problem, and why they needed my username and password.
Well, it’s good to purge once in a while I suppose…
December 29, 2008
For a while I’ve been looking for a way to add error bars in R. It’s actually not that trivial in some cases, and I think that I wrote my own m-script to do it in matlab for bar plots.
At any rate, Google is my friend, and I found a really good post detailing how to do this. In a nutshell, just grab the gplots package and look at the plotCI function. Works great. The only thing I had to tweak was that the uiw is how far from the mean value you want to go (say, S.E., and not mean + S.E.).
October 5, 2008
I had been having trouble upgrading to the latest ipython (0.9.1) through macports. In fact, at this point I can’t even access the site, so I’m not sure what’s up. At any rate, the upgrade would fail only because the file ipython-0.9.1.tar.gz couldn’t be downloaded (well, I guess the source file is somewhat important!). So to get it to work I kind of had to brute force it by manually downloading the file (I googled it) and putting it in /opt/local/var/macports/distfiles/python.
Then I ran:
sudo port upgrade py25-ipython
and it went just fine.