EdgeCalculator(bin,​start,stop,varargin​)

extracts left-bins between starting/stopping range given a set bin width
207 descargas
Actualizado 19 feb 2016

Ver licencia

%-------function [edge,splitdata,lastbin] = EdgeCalculator(bin,start,stop,varargin)------------
%
% Calculate edge times/samples given a user-defined bin width and start/stop range.
% This is useful for things such as PSTHs, histograms, sliding averages,
% permuation entropy, etc. etc.
%
% >>> INPUTS >>>
% Required:
% bin = bin width (in samples)
% start = starting time (samples)
% stop = ending time (samples)
% Optional:
% Fs = sampling rate...useful for converting edge samples to time
% (put 0 as place holder if you want samples)
% data = data array (not matrix) to be split into segments
%
% <<< OUTPUTS <<<
% edge = edge times (in samples, seconds, or ms)
% splitdata = *optional* if input data array as optional argument,
% will split into segments of equal-sized/spaced data
% lastbin = if length(data) < stop, will find the next index
% from "edge" that can be used to parse the data (i.e. up
% to bin X).
%
% By JMS, 08/14/2015
%------------------------------------------------------------------------------------------

Citar como

Jordan Sorokin (2024). EdgeCalculator(bin,start,stop,varargin) (https://www.mathworks.com/matlabcentral/fileexchange/55489-edgecalculator-bin-start-stop-varargin), MATLAB Central File Exchange. Recuperado .

Compatibilidad con la versión de MATLAB
Se creó con R2013a
Compatible con cualquier versión
Compatibilidad con las plataformas
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Versión Publicado Notas de la versión
1.0.0.0