Friday, December 4, 2015

Adding xlwrite to Matlab Static Path

Disclaimer: I'm not sure if the following steps going to mess up your system. This is what works for me, atm. Use at your own risk.

In my earlier post, I added the xlwrite and its needed 6 jar files to Matlab dynamic path. However every time I restart Matlab, I have have to re-do this setting again. I hate going back to my own post and checking out the steps, spending another 1 min to set up the system to use xlwrite. I know 1 min is nothing, but I like things automated. To go about this, add the jar files to Matlab static path. Check here for more about Static Path vs Dynamic Path.

I look everywhere on how to add jar files to static path. I didn't find any clear instructions on how to edit the classpath.txt, anyway this is what works for me.

Steps:

1. In Matlab command window:
>> edit classpath.txt
2. M-file will open. MATLAB reads the static class path only at startup. You can see these are all the files loaded at startup. Eg:
$matlabroot/java/jar/zh_CN/web_connectivity_res.jar

3. We want Matlab to load our desired jar files at startup too. So put your jar files (poi_library) in matlabroot/java/jar/. Where on earth is this place? I'm using Mac, so that place is
Applications> Matlab>right-click>Show Package Contents>Java>jar

matlabroot/java/jar

4. Back to Matlab, append the following at classpath.txt
$matlabroot/java/jar/poi_library/poi-3.8-20120326.jar
$matlabroot/java/jar/poi_library/poi-ooxml-3.8-20120326.jar
$matlabroot/java/jar/poi_library/poi-ooxml-schemas-3.8-20120326.jar
$matlabroot/java/jar/poi_library/xmlbeans-2.3.0.jar
$matlabroot/java/jar/poi_library/dom4j-1.6.1.jar
$matlabroot/java/jar/poi_library/stax-api-1.0.1.jar

Append classpath.txt
 5. Save and restart Matlab.


Note: If you have warning regarding 'undefined xlwrite function', means you haven't set the path to xlwrite yet. To set the path:


Tuesday, December 1, 2015

Thai Color Run - Happiest Run on The Planet

I don't usually register for such short run, 3 km or 5 km, but I made an exception for The Color Run. According to their website it is a paint race, hosting more than 300 events in 50+ countries in 2014. Coincidentally, Thai Color Run was just around the corner during my trip to Bangkok. I was already late for the normal fee, but registered anyway THB 900. Sob sob.. quite expensive for such a short run. Never mind just for the experience, running in a foreign country.

But my feet was quite sore after 3 days wandering in Hua Hin, the southern Thailand. My run was on 1st November 2015. Now I thank God for it was just for a short run. 

I can't really remember the order of the color threw at me, I think start with purple, orange,  yellow, blue, green.

The run is a bit different than what I used to. This is more like fun run, you can just walk or crawl if you wish. The running is by section, I guess maybe the route in Jatujak not allow all to run to the finish line together. During the run you have to stop and wait at certain sections so the runner before you can finish the route before you run that route. I mean the sections were overlap. The park wasn't close for the color run purpose, you can see some others jog and cycling in the park. 

Anyway, let's just see the pics post, shall we?



Before start: running by section, waiting in my section.
KM 2
Waiting ...
Can just walk the 5 KM
KM 3
KM 5
Yeay.. finishing line
Color party afterwards



Project 33 - Purging My Closet

I always want to live with minimum things/ no attachment to whatsoever and to be able to just pull one luggage out from the door if I have to. Such freedom, not tying to anything and buried with everything. If it was something really darn expensive that I can sell then it would be good, but mostly are those unnecessary and sentimental value items.

One small step at a time. Just like most girls/women, I have more clothes than the number of days in a year. Yesterday I was shopping and saw H&M taking clothes donation for recycling purpose, in ex-change for 15% voucher. I'm not a big fan of H&M but this is a good chance to let go of clothes and putting it to good use.

Ok, just 4 links to get me started...

The Project 333
Into Mind
Capsule Wardrobe 101
Infographic - A Guide to Organising Your Wardrobe


Ganbatte ne!