CountAlongAxis¶
Returns the number of items contained in an axis.
Can be used, for example, to return the number of trials or time points in the data. This can also be used to count the number of events in a marker stream. Note that this will return None if there is no matching stream. Version 1.2.0
Ports/Properties¶
data¶
Data to process.
num_items¶
Number of items in the given axis
axis¶
Axis along which to count. Select the space axis for channels, instance axis for trials or segments, time for the number of time points, feature for the number of features in the stream, frequency for the number of frequencies, etc. You can also enter the axis label here as in feature.mylabel to further narrow down along which axis to count if there are multiple of the same type. If the incoming data is a plain array instead of a packet, or you know the order of axes, you can also pass an integer as the index of the target axis. The default value will resolves to the 0th axis in a plain array.
stream¶
The name of the stream on which to operate. If unspecified, first stream containing the specified axis will be counted. Wildcard characters (? *) are allowed for pattern matching, i.e., mystream* will match all streams that start with mystream.
stream_name¶
allow_markers¶
If True and axis='instance' this will count the number of event markers if the first matching stream is an event stream.
set_breakpoint¶
Set a breakpoint on this node. If this is enabled, your debugger (if one is attached) will trigger a breakpoint.
metadata¶
User-definable meta-data associated with the node. Usually reserved for technical purposes.