ca.nengo.util
Interface Probe

All Known Implementing Classes:
ProbeImpl

public interface Probe

Reads state variables from Probeable objects (eg membrane potential from a Neuron). Collected data can be displayed during a simluation or kept for plotting afterwards.

Author:
Bryan Tripp

Method Summary
 void collect(float time)
          Processes new data.
 void connect(Probeable target, java.lang.String stateName, boolean record)
           
 void connect(java.lang.String ensembleName, Probeable target, java.lang.String stateName, boolean record)
           
 TimeSeries getData()
           
 java.lang.String getEnsembleName()
           
 java.lang.String getStateName()
           
 Probeable getTarget()
           
 boolean isInEnsemble()
           
 void reset()
          Clears collected data.
 void setSamplingRate(float rate)
           
 

Method Detail

connect

void connect(java.lang.String ensembleName,
             Probeable target,
             java.lang.String stateName,
             boolean record)
             throws SimulationException
Parameters:
ensembleName - Name of the Ensemble the target object belongs to. Null, if the target is a top-level node.
target - The object about which state history is to be collected
stateName - The name of the state variable to collect
record - If true, getData() returns history since last connect() or reset(), otherwise getData() returns most recent sample
Throws:
SimulationException - if the given target does not have the given state

connect

void connect(Probeable target,
             java.lang.String stateName,
             boolean record)
             throws SimulationException
Parameters:
target - The object about which state history is to be collected
stateName - The name of the state variable to collect
record - If true, getData() returns history since last connect() or reset(), otherwise getData() returns most recent sample
Throws:
SimulationException - if the given target does not have the given state

reset

void reset()
Clears collected data.


collect

void collect(float time)
Processes new data. To be called after every Network time step.


setSamplingRate

void setSamplingRate(float rate)
Parameters:
rate - Rate in samples per second. The default is one sample per network time step, and it is not possible to sample faster than this (specifying a higher sampling rate has no effect).

getData

TimeSeries getData()
Returns:
All collected data since last reset()

getTarget

Probeable getTarget()
Returns:
The object about which state history is to be collected

getStateName

java.lang.String getStateName()
Returns:
The name of the state variable to collect

isInEnsemble

boolean isInEnsemble()
Returns:
Whether the target the node is attached to is inside an Ensemble

getEnsembleName

java.lang.String getEnsembleName()
Returns:
The name of the Ensemble the target the Probe is attached to is in. Null if it's not in one