From: ImageAnalyst on
I'd recommend that you convert your m-fles into functions instead of
simple scripts that just leave variables hanging around in the base
workspace. Then have a master program (which can be a script) that
will call those functions and accept the relevant variables that they
return and then use them. This is a much more organized way that just
a loose collection of a bunch of scripts. Please read in the help
"Getting started/Programming/Scripts and functions."

If you must do it that kind of sloppy, disorganized way, then you can
have one script get variables from the base workspace (that other
scripts loaded in there and left there) into the local workspace of
that script or function by using the evalin() function. Actually I
think a script might automatically see the base workspace so it might
only be a function that would have to use the evalin() command.
Please read the documentation for evalin().

Examples
This example extracts the value of the variable var in the MATLAB base
workspace and captures the value in the local variable v:
v = evalin('base', 'var');