sg-s / xolotl

A MATLAB neuron simulator. Very fast (written in C++). Flexible (fully object oriented). Immediate (live manipulation in MATLAB). Comes with a powerful parameter optimizer. Get started ➡️
https://go.brandeis.edu/xolotl
GNU General Public License v3.0
45 stars 8 forks source link

Added currentscapes for multicompartment models #573

Closed eomorozova closed 3 years ago

sg-s commented 3 years ago

Some things that need to change:

  1. linspecer doesn't resolve ... i think you meant to use colormaps.linspecer?
  2. output_type is changed by the method, but not restored to the original state
  3. y-axes are labelled "%" but it's actually a fraction
  4. each compartment is plotted in a different figure, but there is no way to know which figure is which compartment
  5. running the same method twice throws an error (because the different figures aren't referenced correctly)
  6. If I close on of the figures, and run it again, new figures are created and the old ones aren't updated
  7. Colors for the different currents are not conserved across compartments. It's possible for the same current to have different currents in different compartments
  8. Ideally we would want a single currentscape method that worked for any number of compartments
  9. If the design decision is to make a new figure for each compartment, shouldn't a better architecture be to simply call currentscape many times?
  10. calling it with outputs throws an error because the voltage is not assigned.
sg-s commented 3 years ago

Unfortunately, this will not be merged even though it works as advertised for the following reasons:

  1. duplicate functions currentscape and currentscape_multi
  2. complex architecture which will make maintenance difficult
  3. In my mind, a currentscape method should be recursively engineered, so that calls to it with multiple compartments should call itself over and over again for the different compartments.