I am new today to NEURON and have a simple question. After I do a simulation of say an action potential, how do I get the action potential out into a file I can use in other programs. That is, how can I export the action potential as a binary file or an ascii file or something useful? Any help would be appreciated.
Thanks
DC
Simple Question Output File
-
- Site Admin
- Posts: 6384
- Joined: Wed May 18, 2005 4:50 pm
- Location: Yale University School of Medicine
- Contact:
Re: Simple Question Output File
Quick and dirty method is to use the Print & File Manager's "Print / ASCII". To learn how, go to the FAQ list
http://www.neuron.yale.edu/neuron/faq/general-questions
and look for the question
How do I print a hard copy of a NEURON window?
http://www.neuron.yale.edu/neuron/faq/general-questions
and look for the question
How do I print a hard copy of a NEURON window?
Re: Simple Question Output File
You might want to look at Konstantin Miller's post:
https://www.neuron.yale.edu/phpBB2/view ... antin#p290
This solution works very well with matlab, but it should be possible to port it to other environments. I would like to hear it if someone has a python implementation ready.
In my work I found it easiest to keep things simple and stick to one variable per output file, so no complicated processing of the header of the binary is necessary and you can use Konstantin's code as is. With parameter scans and networks this can be a bit of a problem and you have to make sure that your file system can handle the number of files generated, but splitting the output over several directories can also solve problems.
https://www.neuron.yale.edu/phpBB2/view ... antin#p290
This solution works very well with matlab, but it should be possible to port it to other environments. I would like to hear it if someone has a python implementation ready.
In my work I found it easiest to keep things simple and stick to one variable per output file, so no complicated processing of the header of the binary is necessary and you can use Konstantin's code as is. With parameter scans and networks this can be a bit of a problem and you have to make sure that your file system can handle the number of files generated, but splitting the output over several directories can also solve problems.