sha256 stringlengths 64 64 | language stringclasses 28
values | size int32 1 491k | lines int32 1 23.2k | content stringlengths 1 200k |
|---|---|---|---|---|
0339fffe199ee625c3a8ee4299c61f13415055af2a839f81217b2c3e0cb954a1 | MATLAB | 8,309 | 163 | function [designMatrix designMLabels] = ReffuncToAFNI(RefFunc, SubjectArray, NumRunsTotal, RunsToInclude, RunLengths, TRInSecs, CondNames, CondSearchStrings, RegExpr, OutputToFiles, AnalysisName)
%
%This function takes an array of condition labels (reference function) and creates a series of text files (one per stimu... |
1661cb8de40d9047c7189b44b785f83e1e6eba7bd2baf2f0b2b21b98a92a56af | MATLAB | 8,309 | 153 | function [hdr, fid, cleanupObj] = read_nifti2_hdr(filename)
% READ_NIFTI2_HDR
%
% Use as
% [hdr, fid, cleanupObj] = read_nifti2_hdr(filename)
% where
% filename = string
%
% cleanupObj MUST be kept around until you are done reading from fid,
% as it will close fid when it is ... |
ba314a3039e820422c0a1ee44b09b66555f3ec4e047364eefefb3f53ee25ccb4 | MATLAB | 8,311 | 232 | % calibrate the tranformation between the camera space and the
% DMD space; then find the beads in the field using the bottom camera, and store the
% positions in a variable int he DMD space to be used as "neurons"
%% here must be changed using the BASLERcamera object
% BASLERvid = videoinput('gentl', 1, 'Mono8')... |
f36ad1573c7c1e234d152b388ad6d542bfedcddfe8212179cb60fe6c6ad4408d | MATLAB | 8,333 | 235 | %% analize DTA
clear
clc
cd('I:\My Drive\ELYASHIV\PFC_paper_results_after_revision\DTA\all_ints_data')
DTA = importdata('all_ints_data_DTA.mat');
C57 = importdata('all_ints_data_C57(all_cells).mat');
CONTROL = importdata('all_ints_data_control(mcherry).mat');
%% add tags
DTA.tag = repmat({'DTA'}, size(... |
596f50c8e7325e91e7ecc857e84f33d485fbd4d7665341b693a84038ac51ee2e | MATLAB | 8,346 | 157 | %% 1. retrieve data
disp('select brain region folder about combined files');
Folder_region = uigetdir('E:\Wang_combined files\mat\');
FileList_SpikMat = dir(fullfile(Folder_region, '**\*Spike*.mat'));
FileList_lickMat = dir(fullfile(Folder_region, '**\*lick*.mat'));
session_str = extractAfter(Folder_region,asManyO... |
8a8a5d307ea23c853d796afc1e87058d8ced75937b1f75251e7b5fc938c8be06 | MATLAB | 8,351 | 298 | %% analyse FA single trials (fit separattely)
%% load dataa
sessionTags = {'M22027', '20220517';...
'M22029', '20220607';...
'M22031', '20220524';
'M22032', '20220621';
'M22033', '20220706'};
dataDir = 'C:\Users\edward.horrocks\Documents\Code\V1Dynamics\Data\basic_111022';
s = struct;
for isession =... |
696d0a62a47e44480e46e51c6a55a0a4f24e439718dd24fed3c6222f35efa18b | MATLAB | 8,361 | 202 | function Repeat_20230510
global dpath fname tfile render RpegTouchallWon LpegTouchallWon SpikeArrayWon tfile pegpatternname trimFolder2 pegpatternum ...
LtPositiveFiringRate RtPositiveFiringRate LtPositiveFiringRateP1 RtPositiveFiringRateP1 LtStep4FiringRate RtStep4FiringRate Spikeposition Windowinterval ...
... |
d096e26c369f15815f8d6ca60dd9c9a67750dd60b05c85b55990905e9405929a | MATLAB | 8,361 | 184 | function update_spectral_axis(app,static)
%UNTITLED Summary of this function goes here
% Detailed explanation goes here
int_idx = find(strcmp(app.popup_int_spect.Value,app.popup_int_spect.Items));
% cols = {[0 0 1],[1 0 0];[0 1 0],[0 1 1]; [1 0 1],[1 1 0]};
cols = {[0 0.4470 0.7410],[0.8500 0.3250 0.0980];...
... |
e925b17a6a65ef30ebd095dadc73adb90397af7bba2e246c038443d50f002202 | MATLAB | 8,369 | 216 |
%% Init:
clear
close all
clc
path(pathdef);
addpath( genpath( 'Source' ) )
%% Load a sononerf, a 3D model, etc
load('DataCalculated/TrainedSonoNERFs/sonoNerfTrained - UALogo.mat')
[ surfaceFaces, surfaceVertices ] = stlreadNonCleaning("Data/Models/UALogo.stl");
surfaceVertices = surfa... |
4241e41204409b0dba6ad2c5f1b605eb8b08bb187b0780672d60bceeca193049 | MATLAB | 8,381 | 212 | function [ERP,params] = batchERP(pname,params)
useZeroPhaseFiltering = params.zeroPhase;
%% Initialize variables
ERP.eeg = [];
ERP.erp = [];
ERP.stim = [];
ERP.echtPhase = [];
ERP.echtPhaseLabel = [];
ERP.aPhaseOn = [];
ERP.aPhaseOf = [];
ERP.aPhase = [];
ERP.tPhase = [];
ERP.erpStim = [];
ERP.halpha = [];
ERP.walpha ... |
6381ecbf6f1e4f1cbac3b0f2cff369e731e0aeb797f816aee79b7150e77ff932 | MATLAB | 8,385 | 201 | function update_correlation_axis(app)
if isempty(app.corre_res)
yyaxis(app.ax_signals_corre,'left')
cla(app.ax_signals_corre)
yyaxis(app.ax_signals_corre,'right')
cla(app.ax_signals_corre)
cla(app.ax_signal1_corre)
cla(app.ax_signal2_corre)
cla(app.ax_corre_1_1_1)
cla(app.ax_corre_1_1_2... |
a1de093aa7e0792c7d5d168fd3caef84f6a5b90f7c2edac44ab4a64b01b7d688 | MATLAB | 8,394 | 245 | function [valid] = annotationTool(p,sub)
%% specify output file
savePath = fullfile(p.rootDir,'miniscope',['subject' num2str(sub)],'jointExtraction','sorted','PCAICAsorted.mat');
if exist(savePath)
existing_annotation_warning
return
end
%% get necessary data
% get heuristi... |
1729ad2fa289f256d2942605dc96e9eb9602095384a6aac87851ccdf45ee85b2 | MATLAB | 8,400 | 281 | % Fixed Point Continuation (FPC) for l1 Regularized Least Squares
%
%--------------------------------------------------------------------------
% GENERAL DESCRIPTION & INPUTS
%--------------------------------------------------------------------------
%
% Out = fpc(n,A,b,mu,M,opts,varargin)
%
% Solves
%
% min ||x||_1... |
02402a89b7ee941c5c0e34f23a8bddc342d6786df96b940bb8757d1e5a4aa799 | MATLAB | 8,404 | 233 | function [LRLphase,RLRphase]=PhaseAnalyzer(LTouchAll,RTouchAll)
global RpegTouchCell LpegTouchCell TurnMarkerTime OneTurnTime LRLphase RLRphase LRLbefore RLRbefore IntervalR IntervalL...
RatioAlikeLRL RatioAlikeRLR RatioBlikeLRL RatioBlikeRLR DrName FigureSave fig_LRLphase fig_RLRphase fig_Phasehist DrName..... |
3a6ce4b87c7ed17131ae73719b5200c854351a8f80d3fb3f5789c887141246c0 | MATLAB | 8,408 | 248 | % clear
clc
initialize_human_anxiety %AZ 2023_07_10
biasVes=[];
biasVis=[];
meanBias_Ves=[];
meanBias_Vis=[];
pVec=[];
pVec_ves=[];
pVec_vis=[];
% loading result files
if use_log %AZ 2023_07_11
condLabel={'ResultsVES_all_log.mat','ResultsVIS_all_log.mat',};
else
condLabel={'ResultsVES_all.mat'... |
44ab6913e33e8a8e9b03db2c28baacec43d919d8a3d87ce8cb1e85e61bdde07c | MATLAB | 8,429 | 270 | %% B64's soma
% capacitance of B64's soma
Cm_B64s = 0.01; % uF
% leaky conductance of B64's soma
gL_B64s = 0.1; % uS
RL_B64s = 0; % uS
% reversal potential of the leaky channel of B64's soma
EL_B64s = -60; % mV
% sodium currents to the soma of B64
% maximal conductance of the sodium channel of B64's soma
gNa_B64s = ... |
491cf3253589b2b9065c8afd2a7726613b848b9c5810eebbe031e53d0cd3b5b0 | MATLAB | 8,442 | 224 | function W3_Pattern_4_20201208
path=['C:\Users\C238\Desktop\touchcellLtRt_Hirokane'];
cd(path);
LS=ls;
LtWFRUnit=[];
RtWFRUnit=[];
LtW123Point=0;
LtW123Fire=0;
LtW234Point=0;
LtW234Fire=0;
LtW345Point=0;
LtW345Fire=0;
LtW124Point=0;
LtW124Fire=0;
LtW125Point=0;
LtW125Fire=0;
LtW134Point=0;
LtW134Fire... |
c2d6b783b85b73e8a47499de0b23adef02d7a130318410ae603bf70abfae94a0 | MATLAB | 8,443 | 224 | function W3_Pattern_4_20200302
path=['C:\Users\C238\Desktop\touchcellLtRt_terashita'];
cd(path);
LS=ls;
LtWFRUnit=[];
RtWFRUnit=[];
LtW123Point=0;
LtW123Fire=0;
LtW234Point=0;
LtW234Fire=0;
LtW345Point=0;
LtW345Fire=0;
LtW124Point=0;
LtW124Fire=0;
LtW125Point=0;
LtW125Fire=0;
LtW134Point=0;
LtW134Fir... |
19f4fc8d7c52d354b9fc5c99777e76176a4540356d2600b74f5154fb6e659995 | MATLAB | 8,480 | 244 | function [diff,CI,p,alphav,h]= rst_multicompare(Data,Pairs,varargin)
% Performs multiple comparisons between pairs (repeated measures) based on
% a percentile bootstrap on differences - the alpha value is adjusted to
% control the type 1 error rate. This is not the same as post-hoc testing
% in ANOVA in which signif... |
6f8facda03803e5be95a53224e2d3211f0418fc0f36e5efbe6b855cca2053d3c | MATLAB | 8,482 | 204 | function [ ePE, ordPatPlot, ordDistPlot ] = ...
opdPE( x, delay, order, orderOPD, windowSize, timeScale, timeUnits )
% OPdistVis.m efficiently computes [UK13] and plots the following ordinal characteristics for time series x:
% sequence of ordinal patterns, ordinal distribution and permutation entropy [BKP02]
% acco... |
82c9ec07feed7353f27a1b2b1e215dfef7152c92a182e1b6d353dbabdd36aaef | MATLAB | 8,489 | 243 | % Copyright 2024 Eelke Spaak, Donders Institute.
% See https://github.com/Spaak/rift-phase-and-visibility for readme/license.
% Belongs with:
% Spaak, E., Bouwkamp, F. G., & de Lange, F. P. (2024). Perceptual foundation and extension
% to phase tagging for rapid invisible frequency tagging (RIFT). Imaging Neuroscience,... |
5240c4957a29520deefdba0e83636ff66345810368558fc6120d35aaaf4c73f7 | MATLAB | 8,491 | 163 | function [Table_csv] = extract_ecg_features_leadwise(signal_name, data, fs , ...
increasing_ECG_beat_length, ...
flag_post_processing, ...
... |
a08f51b49e7d7836b8d0e83f8c9685af41921e0098a2d377f67eb4540bfb3f5b | MATLAB | 8,501 | 268 | function res = RaguMSStats(d,h)
% Copyright 2009-2011 Thomas Koenig
% distributed under the terms of the GNU AFFERO General Public License
nClas = size(d.MSMaps,1);
%rng('shuffle');
%s = RandStream.create('mt19937ar','seed',sum(100*clock));
%if verLessThan('matlab', '7.0.1')
% rand('seed',sum(100*clock));
%else
%... |
882f1751b5b1369facf98bf18527b84369816ca2ec895573794393e5096cf496 | MATLAB | 8,507 | 212 | function out = getSiemensRotMatAndShift(hdr)
% input 'hdr' should be twix_obj.hdr
%
% matrix O corresponds to the Siemens internal usage, such that( PE ; RO ; Slice) = O *(x_anat - s_anat)
% Anat is Sag Cor Trans = Left Posterior Head
%
% Assumption for checks : Siemens uses FFT for kspace -> image space ('confirmed' b... |
6e4adb8690361a8617d30aef19fd06c68ab8ac1101cbcad94573c74cf5585079 | MATLAB | 8,530 | 309 | classdef ellipsoidalFit<quadricFit
%A class for executing and managing ellipsoid fits
properties (SetAccess=protected, Hidden)
aDiam
bDiam
cDiam
end
properties (SetAccess=protected)
center
end
properties (Dependent,Hidden) ... |
48e9bdf428bc6774f60458bf75aca6f5caa177f0e882834259ca66ff3b5059a0 | MATLAB | 8,558 | 174 | function p = pathdef
%PATHDEF Search path defaults.
% PATHDEF returns a string that can be used as input to MATLABPATH
% in order to set the path.
% Copyright 1984-2007 The MathWorks, Inc.
% DO NOT MODIFY THIS FILE. IT IS AN AUTOGENERATED FILE.
% EDITING MAY CAUSE THE FILE TO BECOME UNREADABLE TO
% THE ... |
778fbb5cf0d787dd25af6db1395bed6278cae97c63d0267afabdb8d4d821ac70 | MATLAB | 8,591 | 234 | %{
----------------------------------------------------------------------------
Analyzing behavioral data
At least for the correct rate
----------------------------------------------------------------------------
%}
function B = Figure1e_Dual_behave_analysis_block1_220818_lick_short
analysis_folder = {
... |
a408be5c8c3323c31f622a45b12452835c96dd0a8061bf1823e8fb61fdfac9fb | MATLAB | 8,594 | 250 | close all;
clear;
clc;
% parameters
subject1 = 'Dog_3';
subject2 = 'Dog_3';
number1 = 8;
number2 = 8;
path1 = ['J:\Seizure\' subject1 '\'];
path2 = ['J:\Seizure\' subject2 '\'];
mode1 = 'interictal';%'preictal';
mode2 = 'preictal';%'interictal';
epochlen = 30; % epoch length in seconds
epochoverlap = 20; % overlap bet... |
89aaa81ce339c2f433f79083f4bd8490a6e6b9e74a64f6c14fe83291ee2aaae2 | MATLAB | 8,600 | 139 | clear;
close all;
clc;
addpath 'G:\Sameni\Documents\Papers\Journal 40 (Spline ECG Filtering)\CODES'
randn('seed', 0);
rand('seed', 0);
% % % dbstop if warning
type = {'Normal', 'Arrhythmia', 'PTB'};
for ttp = 1 : length(type),
switch(type{ttp})
case 'Normal'
pth = 'J:\ECGData\Normal';
... |
d11379b249a3bdc46b5e5ef879b1341cf4f348034e632ccc327436346cd2af59 | MATLAB | 8,603 | 268 | function entiresessionPhotomPlot_StandardV2(x,y,eb,setupParam,TrialParam,allTrials)
allTrialsID = allTrials.ID;
if setupParam.CompareGroups == 1
% GroupParam = TrialParam.GroupParam;
groupnames1 = fieldnames(allTrialsID);
groupidx = zeros(1,numel(groupnames1));
for i = 1:numel(groupnames1)
... |
3534ee59afcf1bc2c0420300bf4dca0f4c7886d0dc7a6e154413fc23b1d5ada8 | MATLAB | 8,605 | 222 | function CCSfigureSaveTouch20200121
% Fs = 1000; % TvOüg
% t = 0:1/Fs:1; % ÔxNg
% x = sin(2*pi*5*t) .* sin(2*pi*100*t); % Ô²M
%
% F = fft(2*abs(x).^2);
% f = Fs * [0:length(F)-1] / length(F);
% F( f>10 & f< (Fs-10) ) = 0;
% y = ifft(F);
% plot(t,x,t,sqrt(y))
path=['C:\Users\C238\D... |
93472dcdf78377d1917dd3a95750c6226ec50e178733dcd7190f7eea73f4df26 | MATLAB | 8,605 | 227 | function varargout = SingleDim(varargin)
% HELP NEEDS TO BE EDITED
%
% SINGLEDIM M-file for SingleDim.fig
% SINGLEDIM, by itself, creates a new SINGLEDIM or raises the existing
% singleton*.
%
% H = SINGLEDIM returns the handle to a new SINGLEDIM or the handle to
% the existing singleton*.
%
% ... |
29302c1ba01971ce83ae858930f5f587b89ce1c82bbc05525f1ccbca6f9a557f | MATLAB | 8,606 | 153 | % szûrés, epocholás, artifact rej., hibás válasz kidobás, kül. eseményeknek megfelelõ set-ek
%filtering, epoching, artifact rejection, deleting not correct answears,
%creating sets
%HDBR data
%eegdir1='G:\BORI\bedrest\RENDEZETT\A) Bedrest_EEG\EEGÖsszes\3.EEGInterpolated'%EllenõrzöttAdatok\';
%eegdir2='G:\BORI... |
8c9fa2dc512cf8254ec14a4b5ecc1820a7f6a0bb6a735e9e5da2658b2bc1af1b | MATLAB | 8,607 | 147 | function WindowApplyPattern1_20210107
global RtouchSpikeOnUnit LtouchSpikeOnUnit RtouchSpikeOffUnit LtouchSpikeOffUnit LtPositiveSpikeOnKaisuuP1 RtPositiveSpikeOnKaisuuP1...
LtPositiveHistogramXaxisP1 RtPositiveHistogramXaxisP1 LtPositiveFiringRateP1 RtPositiveFiringRateP1
LtPositiveSpikeOnKaisuuP1=zeros(1,2... |
21c677e4a5fd72d71f1f1b70f610b73933d62405cddbc5c154876ca9db6fc593 | MATLAB | 8,620 | 311 | classdef planarFit<quadricFit
%A class for executing and managing 3D plane fits
properties (SetAccess=protected)
distance (1,1)
end
properties (Dependent) %Not settable
normal (1,3)
a
b
c
d %settable alias for distance
closestPoint
end
... |
ba1ffa2b3c3ace1b2e98ea7101fd3b729ad132d3ff9f8e97b36a405a11aa53af | MATLAB | 8,627 | 334 | classdef (Abstract) quadricFit < matlab.mixin.CustomDisplay
%A base class for executing and managing 3D quadric fits
properties (SetAccess=protected)
XYZ
yaw=0;
pitch=0;
roll=0;
end
properties (Dependent,Hidden)
R
y,p,r
ypr
end
met... |
946a2394146e57ac1f9309ff2759086478bfaf23a22fc304f0e6ec75e8a6e85b | MATLAB | 8,631 | 203 | function save_spec_res(app)
%UNTITLED save spectral analysis results
% Detailed explanation goes here
[int_idxs,~] = listdlg('PromptString',{'Please select intervals ',...
'to be plotted/saved.',''},...
'SelectionMode','multiple','ListString',app.popup_int_spect.Items);
[form_idxs,~] = listdlg('PromptString... |
94e614a9bed680fe824c4962799c814c4541a6287e13c7e6f0354842ff1e5ee2 | MATLAB | 8,638 | 241 | function [estParams, seq, LL, iterTime] = myem(currentParams, seq, varargin)
%
% [estParams, seq, LL] = em(currentParams, seq, ...)
%
% NOTE: The only difference between this and the original em.m it was copied from
% is that it does not print as much output.
%
% Fits GPFA model parameters using expectation-maximizatio... |
d2792b8dc4b382d5a5321be3d9c60287479abfbd540b5a5be550011ca20cd0e3 | MATLAB | 8,644 | 201 | function [bres, mres, param] = TM_param_fitting(model)
tic;
fprintf('===== start =====\n');
datdir = '';
Nsbj = 20;
Nitr = 150;
bres.pmat_td = cell(1,Nsbj);
bres.pmat_gr = cell(1,Nsbj);
mres.pmat_td = cell(1,Nsbj);
mres.pmat_gr = cell(1,Nsbj);
param.beta = zeros(1,Nsbj);
param.delta = zeros(1,Nsbj);
param.epsilon... |
e4f0c7e70d55485ee6deb83b7fc624dd2458c40f7f33c23a3dcedac7d936b022 | MATLAB | 8,657 | 256 | %% analyse FA fit on sliding windows
sessionTags = {'M22027', '20220517';...
'M22029', '20220607';...
'M22031', '20220524';
'M22032', '20220621';
'M22033', '20220706'};
dataDir = 'E:\V1Data\Data\basic_111022';
s = struct;
for isession = 1:5
tic
fname = [sessionTags{isession,1},'_', sessionTa... |
a4137937c72921f2d3c27221fc23251466844639d7015d599a6839e6653dea99 | MATLAB | 8,659 | 256 | close all
clc
clear
% Load data files
load 89_PNs_array_data.mat
% Load the four odorants used for conditioning experiments
% Hexanol, Isoamyl acetate, Benzaldehyde and Citral
% For each odorant 10 trials
% Each trial is 40 s of data collection binned into 50 ms time bins - 800
% time bins per trial
% Odor pre... |
aea378c5136cf2fcf0d442c1536b7fa4486720af8c72789f2fdf7457813d9b0f | MATLAB | 8,670 | 246 | function ramp_fun(selpath, all_data,exp_name, save_all_data_2_direct)
cd(selpath)
spike_times = readNPY('spike_times.npy');
spike_clusters = readNPY('spike_clusters.npy');
cluster_info = tdfread('cluster_info.tsv');
events_ts = readtable('events_ts.csv');
files_extracted_data = readtable('files_extracted_data.csv');
%... |
e8cb8e9fbe90541908fc031a326b96ddc7b7560c246d8438300c57a11da44c62 | MATLAB | 8,670 | 142 | clear;
close all;
clc;
addpath 'G:\Sameni\Documents\Papers\Journal 40 (Spline ECG Filtering)\CODES'
type = 'PTB';
switch(type)
case 'Normal'
pth = 'J:\ECGData\Normal';
fs = 128;
segstart_list = 0 : 60 : 30*60; % segstart_list = 0 : 600 : 12*3600;
denoiserparam_list = logspace(-8, 3... |
cfa2bc942fd343684197c4e6045d0583cdb5ddc86e9ca629cd8891f4268bb6bd | MATLAB | 8,673 | 256 | classdef (Hidden) comment < handle
%
% Class:
% adi.comment
%
% Holds a comment.
%
% NOTE: Comments can be moved after they are placed. I think
% this means that the comments might not be ordered by ID.
%
% Also comments can be deleted, which might cause gaps in the I... |
ee359faba502b2229d47ab2b7cc937a2ae7338cd2664248ea9b4a47977916aaf | MATLAB | 8,698 | 220 | function [spec_cor] = processing_MEGA(fid_struct,par)
%function [dif_fids fid_cor phase_cor freq_cor] = processing_MEGA(spec_info,par)
% see the help in processing_spec, the same struct par is used with the
% same option
%
% Romain (Oct 2007) : change the input parameters, to take a cell array of fid and
% written by M... |
8c6bc49a32a33fdb535569a275f67c02099b8548cdefce36a1ec73fd9de2a396 | MATLAB | 8,723 | 135 | function [header, data] = XxReadMRC(file)
handle = fopen(file,'r');
header = int32(fread(handle,256,'int32'));
if header(4)>7 % big endian
frewind(handle);
header=int32(fread(handle,256,'int32','b'));
if nargin==1
switch header(4)
case 6
rawimage=uint16(fread(hand... |
848a12b9bf31bc47b768da2e83c2088ad0697549f88ad7c5511f95b7f9bf73e0 | MATLAB | 8,726 | 274 |
function [scores_lsim, Label] = sim_calassification_lsim(C,T,train_number, test_number)
repeat_num = 1;
channel_num_states(1:C) = randi([2,6],1,C);
while(sum(channel_num_states)>25)
channel_num_states(1:C) = randi([2,6],1,C);
end
channel_dim_observ(1:C) = randi([1,5],1,C);
num_gmm_component(1:C) = randi([1,3],... |
8bae8f6866f5b68bc92d6fbdebe38764cc5c99f2d94b992678c75eb1a66abdc5 | MATLAB | 8,735 | 222 | %% use_extract_ir_parameters
clear
clc
% load dreadds all cells
[file, path] = uigetfile('DREREDDS_all_cells.mat');%When the user clicks the load psetion button, a window should open to enable the user to select a file.
cd(path)
load(file)
dreadds_all = all_cells;
nan_cells = find(cellfun(@(x) isempty(x), all... |
aef812e7485408d524d32fdf95605525b3aa442a8a3f6f0c1172ea60a7e6fbc6 | MATLAB | 8,745 | 231 | function [H, pValue, W] = swtest(x, alpha)
%SWTEST Shapiro-Wilk parametric hypothesis test of composite normality.
% [H, pValue, SWstatistic] = SWTEST(X, ALPHA) performs the
% Shapiro-Wilk test to determine if the null hypothesis of
% composite normality is a reasonable assumption regarding the
% population dis... |
f8ac394c3912c3318706fabdea265030bdf7c8b5f3314552756f131d523f79ec | MATLAB | 8,748 | 326 | function [y,t,optw,W,C,confb95,yb] = sskernel(x,tin,W)
% [y,t,optw,W,C,confb95,yb] = sskernel(x,t,W)
%
% Function `sskernel' returns an optimized kernel density estimate
% using a Gauss kernel function.
%
% Examples:
% >> x = 0.5-0.5*log(rand(1,1e3)); t = linspace(0,3,1000);
% >> [y,t,optw] = sskernel(x,t);
% This exa... |
3c1a1421cb2b23bd976f13d911679b608cf7ff9e66ae60c0865f6a17cd5f1583 | MATLAB | 8,767 | 203 | %% load data
clear
robust_indicator_list = ["no", "yes"];
for robust_indicator_counter = 1 : length(robust_indicator_list)
clearvars -except robust_indicator_list robust_indicator_counter
robust_indicator = robust_indicator_list(robust_indicator_counter);
input_folder = '../data/';
input_file = '... |
1f3c4917ae3dddbee202038900e050ca44f0bafacf323a944a8160b71cd2883a | MATLAB | 8,768 | 318 | classdef linear3dFit < matlab.mixin.CustomDisplay
%A class for executing and managing 3D line fits
properties (SetAccess=protected)
XYZ
x1y1z1(3,1) double %line segment end points
x2y2z2(3,1) double
end
properties (Dependent,Hidden)
p1,p2
p1p2
... |
7ec86deffee5c69c4d15ea4f6f000e8089020f8c1bf6515fdeae84e0629828f9 | MATLAB | 8,769 | 290 | % Summarize MSCD:
% This code analyze MSCD partitions of interst (MSPoI) from
% PoIs_selection_topoScale.m
% set path and directory
% ------------------------
options = {};
% info group
% ------------------------
options.grlabel = {'NE','EX'};
% info task
% ------------------------
options.matrices = {'... |
a207d9e1155d950d5100bce821944069b3a634b61c83b946dbd93b6c698b7500 | MATLAB | 8,769 | 196 | function Both_RLt_Pattern_1_20200304
path=['C:\Users\C238\Desktop\touchcellLtRt_terashita'];
cd(path);
LS=ls;
PositiveRLtouchPoint=zeros(1,11);
PositiveRLtouchFire=zeros(1,11);
NegativeRLtouchPoint=zeros(1,9);
NegativeRLtouchFire=zeros(1,9);
PositiveRLtouchUnit=[];
NegativeRLtouchUnit=[];
SumRtouchUni... |
76a719735615f8ec684d34b3694907474e2aae7a5ea82506e974e5307fafa07e | MATLAB | 8,778 | 242 | %{
----------------------------------------------------------------------------
Analyzing behavioral data
At least for the correct rate
----------------------------------------------------------------------------
%}
function B = Figure1e_Dual_behave_analysis_block1_220818_lick_long4
analysis_folder = {
... |
fcf431d06300c74819630f7d1e6e29de288d81983d94759ba2e50fc2c9c8f231 | MATLAB | 8,779 | 207 | % Function to Indentify Ensembles in Neural Activity
% by Clustering (hierarchichally) Neural *Coactivity*
% 2 or more cells in experiment
% Ignores cells that fires less than 0.25% of the ensemble time
% Applies to the Raster after Selection
% *** OUTPUT has to be named with the sufix: _Analysis *****
% Neither ne... |
4128bfc3339ef5d94bfd1ec9f59f0b621fb7ab33d7b3daad3d28332c23841b40 | MATLAB | 8,790 | 217 | function [pitchsig,pitch_taxis] = ...
get_sig_pitch(sig,fs,params,yanalframe_ms,yanalstep_ms,yes_verbose)
% Takes in a signal and returns its pitch (f0).
%
% If params.ptrack_method is set to 'praat' (the default), other Praat
% settings stored in input arg `params` will be used during the Praat call.
% `params` i... |
82240f5b18d83389ceb91a2c35d1ea63e1bb7f79daebb9b4954ce7c7ec22b230 | MATLAB | 8,791 | 251 | function this = read_gifti_file_standalone(filename, this)
% Low level reader of GIfTI 1.0 files
% FORMAT this = read_gifti_file(filename, this)
% filename - XML GIfTI filename
% this - structure with fields 'metaData', 'label' and 'data'.
%________________________________________________________________... |
25ef00a335e1498421f44e40b1678097f806852032bfdedc53cb96c647a56654 | MATLAB | 8,797 | 258 | function [y1,y2,Pbar,Phat,PSmoothed,Kgain,alpha, y3, PPhat, KKgain, margin] = KalmanSmoothingPriorsFilter(x,R, varargin)
% % % % % % %
% % % % % % % [y1,y2,Pbar,Phat,PSmoothed,Kgain] = KalmanSmoothingPriorsFilter(x,b,a,q,r,gamma,wlen,mode),
% % % % % % % ECG Kalman filter using smoothing priors
% % % % % % %
% % % % % ... |
609608c33f5dbf644f8144df86e298361212d352d2508fde646cbe948ee543a6 | MATLAB | 8,797 | 176 | %% Prerequest
% A rhd recording file with following settings:
% ch1.lick signal; ch3.laser; ch4.water; ch5.sucrose; ch6.quinine;
% ch7-9.optical shaft encoder; ch10.camera (jpeg images 5Hz sampling rate)
% ch3-9 can be blank if it is not useful and neural data is not required
% required files: rhd and a folder wit... |
f21eefe6a2d3c176dba8a53dd7f890f9ca2d4999e7d2e2be82b604278ea80304 | MATLAB | 8,804 | 352 | function plot_compare_spectrum(fids,fids2,spec_info,param)
if ~exist('param'), param='';end
if ~isfield(param,'display')
param.display = 'real';
end
if ~isfield(param,'mean_line_broadening')
param.mean_line_broadening = 0;
end
% param.xlim = [0 6];
% param.x_freq = any;
% param.plot_ref_peak ='CRE' plot the... |
fbea55ddceb59f05374ea99d6531477a85fc64ba7961179cf11c2b1c6f933426 | MATLAB | 8,806 | 193 | function write_conc_res_to_csv(conc,resname,high_res,field_list,std_abs)
%function write_conc_res_to_csv(conc,resname,high_res,field_list,std_abs)
%conc is the matlab structure to write
%resname the filename to save
%high_res is 0 or 1 if 1 full precision digit will be written
%field_list to select only some field of t... |
fde618904275f8ac294a52fa04a5a87a29ab0a5fd3577e3e31e4ebdc45842a3c | MATLAB | 8,807 | 327 | %% Housekeeping
clear;
close all;
clc;
%% Load Data
% Select subjects to exclude from group analysis
exSub = {'Sub_151','Sub_152','126'}; %,'Sub_102','Sub_104','Sub_126','Sub_138'};
%% Analysis parameters
% Define pre-processing for raw EEG data
params = echtparams('filterImplementation',0,'fslide',1,'tWin',[-0.5 0... |
1c9718d278b900027400c383132d1dfed6e64ae0962ab1e876bd65e1d6fed551 | MATLAB | 8,809 | 215 | function RLphase190313
global ACresult ACresultW CCresultDrinkOn SpikeArray TurnMarkerTime RpegTouchallWon LpegTouchallWon...
RpNum LpNum CCresultSpike locsP1time locsP2time locsP1time2 locsP2time2 pksA1 pksA2 CCresultRtouchWon CCresultLtouchWon dpath3...
StartTime FinishTime DiffMaxMinR DiffMaxMinL fname... |
7addb3b0e996265f825b615f97e11a9b4b7e6f2566e7525cfeb029691a9313c2 | MATLAB | 8,809 | 184 | function spike_res = transduction_analysis (app)
MIN_CLUSTER=10;
% MSNA = app.data(app.settings.channel_idx.msna).data;
% data = app.data(app.settings.channel_idx.msna).data(app.settings.interval(1,1)/app.data(app.settings.channel_idx.msna).ts(1):app.settings.interval(1,2)/app.data(app.settings.channel_idx.msna).ts(1... |
446ce916dce8c1bdbdb70eb13ad1825f6ab9195cfb72c4744bcb0ff257da996b | MATLAB | 8,825 | 290 | %% Neural Mass Model
% All corresponding code requires Brain Dynamics Toolbox to run the
% following script
%Running test case for parameter fitting
%% adaptation analysis
%% Example code of tweaking parameters for model
sigma = 0.1; %noise term
d = 0.05;
a=1;
sys = StochasticWilsonWTA_Tash_Sigmoid_adapt(s... |
7b1706171c77fe8448f4af3f91406c39ac31cdb82cfd49ef2631a0e104ad6fbb | MATLAB | 8,828 | 270 | function [TouchTiming DetachTiming DrinkTiming]=VoltageAnalysis20170719(dpath,fname,Fig)
%Vt@C©ç^b`ðo@Dataload{^ÌÈ©ÅÄÑo³êéB
%TouchTiming, DetachTiming, DrinkTiming@cªCh,¡ªL^Ô·msÌsñðÔ·
%VÍh¨¨æ»h5ms²ÆÌL^@ÅãÉx5·éKv è %5ms bin
global TurnMarkerTim... |
2c5482933031b52122604cee6f56ea1fa3049327fed7ed77d035e997ea3e947a | MATLAB | 8,829 | 227 | function corre_report(app)
[int_idxs,~] = listdlg('PromptString',{'Please select intervals ',...
'to be plotted/saved.',''},...
'SelectionMode','multiple','ListString',app.popup_int_spect.Items);
[form_idxs,~] = listdlg('PromptString',{'Please select fileformat ',...
''},...
'SelectionMode','multiple... |
6b79870c5bdbe5bb99c2ac7f7b7ab5d570eb3a384f4bf550056ff114f2fc2169 | MATLAB | 8,829 | 316 | function processSession_popAnalysis_fitSep(inputFileName,outputFileName,dataDir)
load(fullfile(dataDir,inputFileName))
%% process trials
% filter trials to the ones we want to analyse and sort according to
% behavioural state
trialsSpeed2D = trials.Speed2D;
trialsSpeed2D(1) = [];
tsd = trialsSpeed2D;
% split trials... |
d1f24c232177c2b810463b486b29f614ed3b33b90afbab2460cf3a252a2e847c | MATLAB | 8,833 | 208 | % Ensembles Transitions: Hebbian Pathway
% Input
% CAGsmooth
% frame_ensembles
% signif_frames
% Output
% Hebbian Sequence Hebbian Sequence
% Ensemble Onset Hebbian Onsets [samples]
% Ensemble Interval Hebbian Intervals [samples]
function [EnsembleIntervals,EnsembleInstancesTimes,Ense... |
c4cab6298c3939c5074581a6236365700f29016ba4cf816fe4adcf3219dcefc4 | MATLAB | 8,848 | 225 | function BurstClusters = aggregate_bursts_into_clusters(Bursts, EEGBroadband, MinFrequencyRange)
% identifies bursts that occur at the same time that are actually the same
% frequency, aggregates them together. Ignores bursts where there wasn't any overlap.
%
% Part of Matcycle 2022, by Sophia Snipes.
% SingleChannelBu... |
7ae8bbfae15a39b3bcf2fda9b2575f7feccf6bcc9dc7434a8b9e3d52859ccce3 | MATLAB | 8,852 | 178 | %% tHit vs. tCR
% Touch-evoked responses
% Chang et al., Fig 1h
% load data array
load('E:\Data_array\AllTrials_10bin_Smooth\data_array.mat')
% Import setting
mainDir = 'E:\CM_NeuralActivity_Analysis\ROC\tHit_tCR_selectivity';
recSites = {'left S1', 'left S2', 'left wM2','left ALM'};
nBoot = 1000;
rng(15)
pos_tt = {[... |
bb9ef1bcc8c991b5840e027fc3b8f9e3db46993a58ce19b4f772997cc8ae6ca5 | MATLAB | 8,855 | 222 | snps=readtable(strcat('D:\Canada_2020\UK_biobank\reports\AD\genetics\EURnoWB\METAL\FUMA_CT1_META\eqtl.txt'));
snps(~strcmp(snps.uniqID, '2:27225144:A:C'),:)=[];
snps(~strcmp(snps.uniqID, '8:27098436:C:T'),:)=[];
%% global
clear
snps=readtable(strcat('D:\Canada_2020\UK_biobank\reports\AD\genetics\EURnoWB\METAL\FUMA_CT1... |
53ca403f67500a582ec6f34369f1718a66a7fcfd9452203c2c2894d238baba40 | MATLAB | 8,858 | 164 | function [align,time,events,fig,sp] = plot_fp2event(beh,varargin)
%Align photometry to event times (reward, movement) and plot average trace
%
% plot_fp2event(beh)
% [align,time] = plot_fp2event(beh)
% [align,time,events,fig,sp] = plot_fp2event(beh)
% [align,time,events,fig,sp] = plot_fp2event(beh,window,... |
38444ecd180138886758033026f6b15a38760b09ea4317217e6d46a22586011d | MATLAB | 8,869 | 339 | %% Housekeeping
% Clear all figures, data, and set a timer.
close all
clear
clc
% Set timer
h = tic;
%% Prep Work
% This is where we load all of our participant files directories', as well as
% parameters for processing the output of the ECHT device and exclude participant's
% with artifacts.
% Load current data... |
3b6d882a7603ef8a10d3e0a4c6f642cfff4fe4c108ca07daf0f8ad83b4ccac76 | MATLAB | 8,871 | 215 | function [WF] = processWF(WF, varargin)
%Process spike waveforms
%
% Description: This function will process spike waveforms for units and
% compute the coordinates of waveform features to be used to compute
% waveform properties
%
% [WF] = processWF(WF, varargin)
%
% INPUT
% 'WF' - structure with ex... |
6ffa80227f6844b07fd1835a5ffc096995ead358833c12e4263c77c35acc74ea | MATLAB | 8,888 | 258 | function [y1,y2,Pbar,Phat,PSmoothed,Kgain,alpha] = ECGSmoothnessPriorsDenoiserKF(x, order, R, Q, gamma, Qadapt, wlen)
% % % % % % %
% % % % % % % [y1,y2,Pbar,Phat,PSmoothed,Kgain] = ECGSmoothnessPriorsDenoiserKF(x,b,a,q,r,gamma,wlen,mode),
% % % % % % % ECG Kalman filter using smoothing priors
% % % % % % %
% % % % % %... |
4d103d55a0b135b7ed8cf0719d1caeac7a36f4339e2b598e66552b9dfec28d89 | MATLAB | 8,890 | 154 | function Chunk_analysis
global RpegTouchallWon LpegTouchallWon SpikeArrayWon tfile pegpatternname trimFolder2 pegpatternum ...
Spikeposition Windowinterval
path="D:\CheetahWRLV20200411";
cd(path);
if not(exist('Chunk','dir'))
mkdir('Chunk')
end
cellnum=0;
patternnum=0;
Touchcellnum = 0;
mod98=0;... |
d3c4f8bb44873154691d71401ee1e718b04f36acb2dc7163f080e76951af1116 | MATLAB | 8,890 | 297 | %% analyse cross-time decoding
sessionTags = {'M22027', '20220517';...
'M22029', '20220607';...
'M22031', '20220524';
'M22032', '20220621';
'M22033', '20220706'};
dataDir = 'C:\Users\edward.horrocks\Documents\Code\V1Dynamics\Data\basic_111022';
for isession = 1:size(sessionTags,1)
fname = [sessio... |
fe6cc792d837cfbd768930790916751f8482673652888ea5c3b91e5f82922616 | MATLAB | 8,896 | 306 | function optimize_hopf_effective_UWS()
load empiricalLEiDA.mat;
P1emp=nanmean(P1emp);
P3emp=nanmean(P3emp);
load SC_template.mat;
C=sc_healthy;
C=C/max(max(C))*0.2;
load fMRI_Liege_2023.mat;
X=tc_gr(:,3)';
TSmax=295;
N=214;
NSUB= 16;
TR=2; % Repetition Time (seconds)
NumClusters= 4; %Number_Clusters;
delt = TR... |
ef8ca5fb5cf0bc2f341e8802676d59bedb0679a3b3de8c597050151ec4754188 | MATLAB | 8,905 | 302 |
% plot ramp data
clear all;
close all;
cd 'D:\Papers and future research plans\paper_Light-sensitive brain networks\Data\Ramp_Nov_23_2022\Ramp revision';
load('ramp and seven intensities data per cluster.mat');
%% Process data
ramp_int(91:120)=[];
ramp_int(1:30)=[];
% reorder data according to the ord... |
1fbbca97289b1ddcf7713ea33d791184116fe2eae247518d3d041c3cec51b7b8 | MATLAB | 8,909 | 258 | %% layer and cell types per cluster form all_psthT
clc
clear
cd('I:\My Drive\ELYASHIV\PFC_paper_results_after_revision\figure5_S_layers')
load('all_cells_PSTH.mat')
%% pool ACd ACv, 6a 6b
change_position_name = all_psthT.position;
AC_names = find(contains(change_position_name, 'ACA'));
change_position_name(find... |
8ef95537236711f1f0d948870cf7a78b30402b14b53be428c3429efdca875c32 | MATLAB | 8,910 | 251 | clear
clc
[file, path] = uigetfile('*.mat','MultiSelect','on');%When the user clicks the load psetion button, a window should open to enable the user to select a file.
cd(path)
%%
n = length(file);
all_psth = cell(7,2);
all_cells = cell(1,2);
ploting = 1;
window_times = {40:50, 65:125, 140:150};
win_names = ["early... |
261decb131cd4a06f0e543bc7e980df7d8c3adc72bfe2cb0b7b44f04d3122480 | MATLAB | 8,914 | 213 | % Function to convert a raw Cerca .cmeg file into fieldtrip format,
% for further analysis.
% Inputs are the raw MEG filename (including filepath).
% Output is fieldtrip data structure.
% Code edited from Nottingham scripts and Cerca Analysis app (Ryan Hill)
% for use at YE (Zelekha Seedat)
%%%%%%%%%%%%%%%%%%%%... |
127ff09772ef1fe7734a461b69fe928824ff931d61e6766b8acbfc6a992555c3 | MATLAB | 8,925 | 186 | function Peak_Variance_ALLTouch_20200303
path=['C:\Users\C238\Desktop\touchcellLtRt_terashita'];
cd(path);
LS=ls;
Seq5LtouchTime=[];
Seq5RtouchTime=[];
MeanCVLtouchArrayArray=[];
MeanRandomCVLtouchArrayArray=[];
MeanCVRtouchArrayArray=[];
MeanRandomCVRtouchArrayArray=[];
CVLtouchPeakArray=[];
CVRtouc... |
667a6342a1cbf986c0a1e10e39fea3a4c0630399d7b0041424d1aeadb4dc8fee | MATLAB | 8,933 | 296 | function processArgs(obj)
%PROCESSARGS Handle command-line arguments, load param file
nargs = numel(obj.args);
if nargs == 0
return;
end
obj.cmd = lower(obj.args{1});
obj.args = obj.args(2:end);
nargs = nargs - 1;
% paired manual commands
if contains(obj.cmd, '-manual')
... |
35978980cfe85db36d6b3b9cad5bb6cd4ceef3487a7d795881f8837b4adcbca9 | MATLAB | 8,935 | 302 | clear
clc
cd('I:\My Drive\ELYASHIV\PFC_paper_results_after_revision\DREEDDS_VS_CONTROL_PHb\all_ints_data')
T = importdata("all_ints_data_control.mat");
T2 = importdata("all_ints_data_dreadds.mat");
%%
T1 = T;
T21 = T2;
T = exclude_changing_cells(T);
T2 = exclude_changing_cells(T2);
%%
before = T(find(c... |
8978c0eaf20f50e0a34f90c345c23cffa88060d6abb03d76236d6293fff41a99 | MATLAB | 8,939 | 217 | function [cent, varargout]=FastPeakFind_bmh(d, sigma, thres, filt ,edg, res, fid)
% Analyze noisy 2D images and find peaks using local maxima (1 pixel
% resolution) or weighted centroids (sub-pixel resolution).
% The code is designed to be as fast as possible, so I kept it pretty basic.
% The code assumes that the pea... |
100a15e92dd4a2d0cb8dfab12e08a4a4ffbf9fbe1bab74bb3282fb7fa373c49e | MATLAB | 8,950 | 178 | % Cardiac model ToR-ORd
% Copyright (C) 2019 Jakub Tomek. Contact: jakub.tomek.mff@gmail.com
%
% This program is free software: you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
% the Free Software Foundation, either version 3 of the Licens... |
7a42574f37c7529dca35bb50f87634c41e4359a13117795beeb13348978e61fe | MATLAB | 8,958 | 271 | % Class "Bitsi"
%
% %Constructor%
%
% Bitsi(comport)
%
% When creating a new 'bitsi' object, you can specify to which comport it
% is connected. On windows computers, this is usually something like
% 'com1'.
% When using an empty string for 'comport', the object will run in testing
% mode. In this case it's ... |
19f2ea5b90512448de0cb4c18046527ef17d2c788b53342a5109ce6f5daeaf8c | MATLAB | 8,960 | 244 | function WeightPreferAttach20171116
% WeightPreferAttach20151231
global Neurons Add
%̽¢èƳçÉðìèâ·¢lbg[N
%xÉæéDæIf
%Ììèâ·³AÅÍêlªzAªÅ«éÆAddÉæèìèâ·³ªÁ
clear all;
close all;
% Reciprocal=0.2;%0ÈOÌÆ«ÉÍA¯É½... |
43feea5c76622e1e524b324be090560962d89c469aabafcc65d605e91db8912a | MATLAB | 8,984 | 194 | function [eeg_refined, Delta, delta] = eog_canceller_nsca(eeg, eog, fs, power_env_wlen, num_itr, th_method, th_value, num_comp_est_method, shrinkage_method, shrinkage_params, adapt_reference, flagplot)
%
% Implements an Electrooculography (EOG) artifact removal algorithm from
% Electroencephalography (EEG) data using N... |
7e5cdb20d80d042c18eefca071dc6faf6b1366553173c721def88446cc432354 | MATLAB | 8,990 | 274 | function install_eq_toolbox(arg)
%INSTALL_EQ_TOOLBOX Install using Toolbox Installer, with sensible defaults
%
%Syntax
% install_eq_toolbox(arg);
%
%Description
% INSTALL_EQ_TOOLBOX uses Toolbox Installer to install this toolbox. It must
% be run from the top level directory of this toolbox, which must contain the
% fi... |
3e686878e7fda98fcfd19fe61deae1164c6945aa4618c1a0a2c093e034df0030 | MATLAB | 8,999 | 277 | % plot the timecourses showing relationship of bursts with lapses
clear
clc
close all
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%% Parameters
SmoothFactor = 0.2; % in seconds, smooth signal to be visually pleasing
CheckEyes = true; % check if person had eyes open or closed
Closest ... |
b8f2a76e6b70db0bd4a77d16f68305a9c0b52a35b62b314ea92e44960066d522 | MATLAB | 8,999 | 196 | classdef spike_pointer < handle
%POINTER manages the data to display and the rwaves to display
% Detailed explanation goes here
properties
start_idx_det
stop_idx_det
start_idx_ov
stop_idx_ov
dur_det
dur_ov
length
overlap
plot_id... |
550ca16e7b65ab7d8b856b2436dea035649eb86c343b960c0cb525e51e3e8718 | MATLAB | 9,004 | 249 | %__________________________________________________________________________
% violin.m - Simple violin plot using matlab default kernel density estimation
% Last update: 10/2015
%__________________________________________________________________________
% This function creates violin plots based on kernel density estim... |
2cbebf2c98185f68aa7007158c239641137f02ceebf7d7850f8931d483882d60 | MATLAB | 9,007 | 221 | function mrprot = parse_mrprot(fp)
% parse mrprot (text) structure stored in an open file
mrprot = [];
done = 0;
while(done == 0)
% read a line
line = fgetl(fp);
% strip any comments
ctest = findstr(line, '#');
if (ctest > 1)
line = line(1:ctest-1);
end
if (... |
b69e1ab6cd40a50bb93597d844747be39aa88757fd5946fa15c9aa6e9e16780d | MATLAB | 9,014 | 216 |
classdef BitCode
methods(Static)
% ComputeBitCode
% Use bitcode to get trial numbers: Bcontrol sends bitcode to Intan through
% digSignal channel
% Reference: cat_session6 and Tongue.Preprocess.ComputeDelimiter
function result = ComputeBitCod... |
4177017ff4d3b50402c3b45c9a2eaab6b860bae738eda00900f5487555d90b28 | MATLAB | 9,016 | 309 | function optimize_hopf_effective_MCS()
load empiricalLEiDA.mat;
P1emp=nanmean(P1emp);
P2emp=nanmean(P2emp);
load SC_template.mat;
C=sc_healthy;
C=C/max(max(C))*0.2;
load fMRI_Liege_2023.mat;
%%%%%%%%%%%%%%%%%%
X=tc_gr(:,2)';
TSmax=295;
NSUB= 29;
N=214;
TR=2; % Repetition Time (seconds)
NumClusters= 4... |
f0f29bb470038b0586b3e58eba3ef6657317b4797a9a55ba963726d3b8574047 | MATLAB | 9,020 | 256 |
function [P_star_model , X_star]...
= viterbi_chmm( pi_0_chmm , coupling_tetha_convex_comb , transition_matrices_convex_comb , chmm_gmm_para , Y_in )
% Y is observations which is a cell size Cx1 where Y{c,1} is the c'th subsystem observations
% C is the total number of subsystems
%Transition probabiliti... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.