def phenotypes(m, par=None): """ Aggregate phenotypes for sensitivity analysis. Wrap CellML model and adjust parameter names to conform with pacing protocol >>> m = Model(workspace="beeler_reuter_1977", rename=dict( ... p=dict(IstimPeriod="stim_period", IstimAmplitude="stim_amplitude", ... IstimPulseDuration="stim_duration")), ... reltol=1e-10, maxsteps=1e6, chunksize=100000) >>> m.pr.IstimStart = 0 >>> print "Result:"; phenotypes(m) Result:... rec.array([ (115.799..., -83.857..., 31.942..., 2.287..., 0.01384..., 127.599..., 217.0..., 256.603..., 273.144..., 0.00612..., 0.000183..., 0.00630..., 92.373..., 0.0336..., 242.2..., 268.75..., 285.98..., 302.226...)], dtype=[('apamp', '<f8'), ('apbase', '<f8'), ('appeak', '<f8'), ('apttp', '<f8'), ('apdecayrate', '<f8'), ('apd25', '<f8'), ('apd50', '<f8'), ('apd75', '<f8'), ('apd90', '<f8'), ('ctamp', '<f8'), ('ctbase', '<f8'), ('ctpeak', '<f8'), ('ctttp', '<f8'), ('ctdecayrate', '<f8'), ('ctd25', '<f8'), ('ctd50', '<f8'), ('ctd75', '<f8'), ('ctd90', '<f8')]) """ with m.autorestore(_p=par): m.eq(tmax=1e4, tol=1e-3) _t, _y, stats = m.ap() return ap_stats_array(stats)
def phenotypes(par=None): with m.autorestore(_p=par): m.eq(tmax=1e7, tol=1e-3) t, y, stats = m.ap() return ap_stats_array(stats)
def phenotypes(par=None): """Aggregate phenotypes for sensitivity analysis.""" with m.autorestore(_p=par): m.eq(tmax=1e4, tol=1e-3) _t, _y, stats = m.ap() return ap_stats_array(stats)