help-octave
[Top][All Lists]
Advanced

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

Re: Calling a function available in .oct file from .m file


From: vivek
Subject: Re: Calling a function available in .oct file from .m file
Date: Tue, 2 Apr 2019 13:36:32 -0500 (CDT)

Following are the files which i have in my casegenplots - Octave script
filegenobsplot_all.m - ".m" file where genobsplot_all function is
availabletmgetevents.oct is an oct file which has tmgetevents function
defined in it. tmgetevents is called from genobsplot_all.mOctave was able to
locate genobsplot_all.m after adding the statement
"addpath("/usr/local/vhosts/logfetch/:");" in genplotsSimilar things were
tried on trial and error basis for tmgetevents.oct but still i am facing
undefined error for tmgetevents
function.**********************************/usr/local/vhosts/logfetch/genplots**********************************#!/usr/local/bin/octave
-qf## takes filename, pulls all obs from that fileif (nargin != 1 && nargin
!= 4)    usage("genplots filename [evid startobs endobs]");endif# set
loadpath to just our local world and the system stuffLOADPATH =
["/usr/local/vendor/bin:/usr/local/vhosts/logfetch/:"];#addpath("/usr/local/vendor/bin:/usr/local/vhosts/logfetch:");addpath("/usr/local/vhosts/logfetch/:");setenv(
"LOADPATH",
"/usr/local/vendor/bin:/usr/local/vhosts/logfetch/:/usr/local/vhosts/logfetch/");autoload('tmgetevents',
'/usr/local/vendor/bin/tmgetevents.oct');ignore_function_time_stamp =
'all';if (nargin == 1)    exit(genobsplot_all( argv ) );else   
exit(genobsplot( argv(1,:), str2num(argv(2,:)), str2num(argv(3,:)),
str2num(argv(4,:)) )
);endif**********************************/usr/local/vhosts/logfetch/genobsplot_all.m**********************************function
retval = genobsplot_all(aFilename)  retval = 255;  if (nargin != 1)   
usage("genobsplots(aFilename)");  endif  evs = tmgetevents(aFilename); 
retval = 0;endfunction**********************************Output of "nm"
command for tmgetevents.oct**********************************nm
/usr/local/vendor/bin/tmgetevents.oct | grep tmgetevents00000000000050e0 t
Gtmgetevents0000000000006230 t _Z12FtmgeteventsRK17octave_value_listi



--
Sent from: http://octave.1599824.n4.nabble.com/Octave-General-f1599825.html



reply via email to

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