Page 1 of 1


Posted: Thu Jul 06, 2006 8:26 pm
by thats_karlo

Can we make any connection from NEURON to MatLab. say, use matlab command in a *.hoc file?


Posted: Sat Jul 08, 2006 11:11 am
by thats_karlo

I forget to say, i use WinXp, and MatLab 6.5

Posted: Tue Jul 11, 2006 8:51 am
by hines
It is simpler if you can turn things around and have Matlab control NEURON. I presume Matlab can interact with a process via stdin/stdout and you would start NEURON with the string
nrniv -nogui -isatty

But if your project is conceptually simpler with Matlab controlled by NEURON then
you can have NEURON load the Java Virtual Machine (but you would need Java installed) and see c:/nrn59/lib/nrn.def with respect to telling NEURON where the JVM is. Then you can use the, popen.hoc example as the idiom for launching a process that NEURON can communicate with through the processes stdin/stdout. If you decide to use the Java method, then send me an email and I'll give you the file with the code.

Re: matlab-neuron

Posted: Sat Sep 21, 2019 1:44 am
by bdut

Adding to this thread, is there a way to call a Matlab user-defined function from .mod/ .hoc file? I am working on Neuron 7.7.2 and Matlab2019.

Thank you