Rank: 332609 based on 0 downloads (last 30 days) and 0 file submitted

jamie mazer


Personal Profile:


Watch this Author's files


Comments and Ratings by jamie mazer View all
Updated File Comments Rating
05 Jul 2014 MySQL Database Connector Connect to MySQL database. Author: Robert Almgren

After going through all comments below, here's are some streamlined instrutions for installing under OSX Mavericks (R2014a).

Step 1 - Install a mysql distribution to get the mysql client libs and headers:

% sudo bash <(curl -Ls http://git.io/eUx7rg)

As of today, this install mysql-5.6.19 -- note the version number -- you need to make sure it matches the command below. You can verify the version installed by looking in /usr/local for mysql-VERSION-osx...

Step 2 - Compile mysql.cpp:

% /Applications/MATLAB_R2014a.app/bin/mex -I/usr/local/mysql-5.6.19-osx10.7-x86_64/include/ -L/usr/local/mysql-5.6.19-osx10.7-x86_64/lib/ -lmysqlclient mysql.cpp

This will generated mysql.mexmaci64. Put it and mysql.m somewhere on your matlab path.

Step 3 - Tell OSX where to find the mysql dynamic libraries by adding:

export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:/usr/local/mysql-5.6.19-osx10.7-x86_64/lib/

to your .bashrc/.bash_profile (or matlab startup script).

Two things that aren't clear in the comments below are (1) mysql version number (currently 5.6.19) can change, so you need to check and (2) the DYLD_LIBRARY_PATH needs to be set to USE the mex file, not to compile it.

31 Jul 2013 GUI Layout Toolbox Layout management objects for MATLAB GUIs Author: Ben Tordoff

Hate to follow up to my own post, but for the record, this doesn't appear to be a subplot issue -- this version that uses uiExtras.Grid does something similar. It's tweaked a bit to really emphasize the proble (nothing's ever plotted in the right hand grid box, but it still accumulates all the plot points:

clist = 'rgbmy';
tabpanel = uiextras.TabPanel('Parent', gcf);
for n=1:4
uip = uiextras.Grid('Parent', tabpanel);
x = 1:2; y = x+n;
set(plot(x, y, '-o'), 'markerfacecolor', clist(n));
tabpanel.SelectedChild = 1;

On the up side, I guess I could include a dummy plot to suck up all the error's leaving the n-1 subplots correct :-)

31 Jul 2013 GUI Layout Toolbox Layout management objects for MATLAB GUIs Author: Ben Tordoff

Quick question -- is it ok to mix uiextras and subplot? At first it looks kosher, but here's a short code frag that breaks things:

tabpanel = uiextras.TabPanel('Parent', gcf);
for n=1:4
uip = uipanel('Parent', tabpanel);
subplot(1,1,1, 'Parent', uip)
x = 1:2; y = rand(size(x));
plot(x, y, '-o');
tabpanel.SelectedChild = 1;

This makes some tabs, each with one plot. 1st tab accumulates all 4 plots, 2nd second tab last 3, etc. I suspect the answer is: don't mix subplot and uiextras, but there's not explicit about that in the docs. Switching to subplots to grids would mean a lot of recoding, so I figured it would be good to know if this is a bug or feature before I decide if it's worth it (FYI - this doesn't happen with hist!).

Contact us