ModelDB is moving. Check out our new site at The corresponding page is

Model of peripheral nerve with ephaptic coupling (Capllonch-Juan & Sepulveda 2020)

 Download zip file 
Help downloading and running models
We built a computational model of a peripheral nerve trunk in which the interstitial space between the fibers and the tissues is modelled using a resistor network, thus enabling distance-dependent ephaptic coupling between myelinated axons and between fascicles as well. We used the model to simulate a) the stimulation of a nerve trunk model with a cuff electrode, and b) the propagation of action potentials along the axons. Results were used to investigate the effect of ephaptic interactions on recruitment and selectivity stemming from artificial (i.e., neural implant) stimulation and on the relative timing between action potentials during propagation.
1 . Capllonch-Juan M, Sepulveda F (2020) Modelling the effects of ephaptic coupling on selectivity and response patterns during artificial stimulation of peripheral nerves. PLoS Comput Biol 16:e1007826 [PubMed]
Model Information (Click on a link to find other models with that property)
Model Type: Extracellular; Axon;
Brain Region(s)/Organism:
Cell Type(s): Myelinated neuron;
Gap Junctions:
Simulation Environment: NEURON; Python;
Model Concept(s): Ephaptic coupling; Stimulus selectivity;
Open the results csv files, read their information and return it

import csv
import os
import numpy as np
from collections import OrderedDict

possible_secnames = [

def read_results(folder):
	""" Just read all the results """

	# Select the csv files
	items = sorted(os.listdir(folder))
	items = [item for item in items if ".csv" in item]

	# Data storage variables	
	# Voltage data
	data = {}
	# Geometrical properties
	xx_ = []
	yy_ = []
	rr_ = []
	# z-axis anatomy
	zprofile = {}

	# Iterate over the files and read them
	i = 0
	for filename in items:
		j = 0
		data[i] = {}
		zprofile[i] = OrderedDict()
		with open(os.path.join(folder, filename), "r") as f:
			fr = csv.reader(f)
			for row in fr:
				isasection = np.array([x in row[0] for x in possible_secnames]).any()
				if isasection:
					data[i][key].append([float(x) for x in row[1:]])
				elif len(row) == 1:
						data[i][key] = np.array(data[i][key])
					except NameError:
						# There's no key yet
					key = row[0]
					data[i][key] = []
				elif "segment positions" in row[0]:
					for item in row[1:]:
							value = float(item)
						except ValueError:
							segname = item
							zprofile[i][segname] = value
				elif len(row) == 3:
					except ValueError:

		# When the last key is read, don't forget storing it
		data[i][key] = np.array(data[i][key])
		# wherenodes[i] = np.unique(np.array(wherenodes[i]))
		del key
		# axondata = np.array(axondata)
		# Store data in the dictionary
		i += 1

	return data, zprofile, (xx_, yy_, rr_)

Loading data, please wait...