help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: private directories


From: James Sherman Jr.
Subject: Re: private directories
Date: Thu, 1 Mar 2012 23:04:43 -0500

On Thu, Mar 1, 2012 at 10:43 PM, Muhali <address@hidden> wrote:
I noticed that private directories are treated differently in matlab and
octave. If in a function a file from the private directory is loaded this is
recognized by matlab but not by octave, as in the following example where
foo.mat resides in /foo/private:

-------------------
% /foo/fun.m
function y = fun()
  load foo.mat
end
-------------------

%> cd /foo; octave --no-init-file -q
octave:> fun
error: load: unable to find file foo.mat
error: called from:
error:   /foo/fun.m at line 3, column 4

Should this be considered a bug or a missing feature?

M.



If /foo/private is not in the search path of octave, it won't be able to find your mat file.  Try
addpath /foo/private

I don't see how matlab would behave any differently unless you have /foo/private added into the path of matlab.

Hope this helps,

James Sherman

reply via email to

[Prev in Thread] Current Thread [Next in Thread]