sha256
stringlengths
64
64
language
stringclasses
28 values
size
int32
1
491k
lines
int32
1
23.2k
content
stringlengths
1
200k
ccb32f2ede48e2c1c3dd78f3d03c563f9fca4abb4202baec0dbfffe84b049f97
MATLAB
45,276
1,162
function [rew,raw] = ltsregres(x,y,varargin) %LTSREGRES carries out least trimmed squares (LTS) regression, introduced in % % Rousseeuw, P.J. (1984), "Least Median of Squares Regression," % Journal of the American Statistical Association, Vol. 79, pp. 871-881. % % The LTS regression method minimizes the sum of...
3eee032daa8602d3a142c6443cc003c80d6255940f6cc48b1743d8484a218a1b
MATLAB
45,643
1,394
function aedes_export_gui(DATA,ROI,Clim_in,colmap_in,roiTransp,showRoiEdges,overlay,currentVol) % AEDES_EXPORT_GUI - Graphical user interface for exporting mri images % % % Synopsis: % % Description: % % Examples: % % See also: % AEDES % This function is a part of Aedes - A graphical tool for analyzing % med...
da186a1f48398c555f85ad96205e1f8669b978be0cb2f2a73c5cb66192fafaed
MATLAB
45,725
1,410
function [DATA,msg_out] = aedes_readvnmr(filename,varargin) % AEDES_READVNMR - Read VNMR (Varian) FID-files % % % Synopsis: % [DATA,msg]=aedes_readvnmr(filename,'PropertyName1',value1,'PropertyName2',value2,...) % [DATA,msg]=aedes_readvnmr(filename,'header') % [DATA,msg]=aedes_readvnmr(filenam...
056d63a13f24bb17faa8de76757f7454b3fd5d63e989c17cf1d133909ed72e75
MATLAB
47,314
850
% presents response maps in units of spikes/paired-event. why > 1?? %amapOF - modified from amap to analyze OpenField data. Oct 2016, ehud. % %amap. ehud,Feb 2016. analyze response maps for pairs of variables. can %plot or save to data base % % run: % a loop over Sessions (SesList = {'ses1';'ses2';,...}) % a lo...
99ac388a53802eaa0b11070f49e10c2ab25c52f6dc917b0e620f14451d147e25
MATLAB
47,895
1,514
%% Code Outline % The following code runs the main GLM analyses but using 1000 Schaefer cortical nodes. %% Load in task data % Baseline + Rotation rootdir = 'D:\PhD\visuomotor_Gallivan\BIDS'; %set path of root directory filelist = dir(fullfile(rootdir, '**\*ses-01_task-rotation_events.tsv*')); %get list of ....
f785c15e3b313d33239fb183b4a62b60e979b79639c05cb64ded1e3783f7ec7c
MATLAB
48,376
1,085
function [HDR,data] = iopen(HDR,PERMISSION,CHAN,MODE,arg5,arg6) % IOPEN opens image files for reading and writing and returns % the header information. Many different IMAGE formats are supported. % % HDR = iopen(Filename, PERMISSION, [, CHAN [, MODE]]); % % PERMISSION is one of the following strings % 'r' read ...
4eef93f3887d9e804ce28b6b2811afce59700a3cca7384b6ef98bca8516c0018
MATLAB
48,611
1,146
% % NeuronFilter - Temporal Labeling GUI for calcium imaging videos of active neurons % Last updated 8/29/2019 by Agnim Agarwal % function NeuronFilter(vid, Mask, markings, trace, DirSave) % markings variable = for external markings OR 0 for no file input % vid is the input video % Mask is the mask of neurons % marki...
835e6b01f7ce7862c83634b94ea01924223099b9a5a6a9d95e92095890b7bd75
MATLAB
49,579
1,745
% makePatternsScript.m % % Script for making all the patterns, ordered in numerical order % % CREATED: 2/14/21 - HHY % % UPDATED: % 2/14/21 - HHY % 3/10/21 - HHY % 1/7/24 - HHY %% Some constants gsVal = 3; % for pattern.gs_val, means 8 possible pixel vlaues % luminance levels meanLum = 3; darkLum = 0; lightLum =...
258368af5afec22b6f8e8c2adc5c3025c31f30323302f5f669d76897a6ef1c25
MATLAB
49,722
1,248
function varargout = nii_tool(cmd, varargin) % Basic function to create, load and save NIfTI file. % % rst = nii_tool('cmd', para); % % To list all command, type % nii_tool ? % % To get help information for each command, include '?' in cmd, for example: % nii_tool init? % nii_tool('init?') % % Here i...
e0ac68157d896018e6f34268a8bca3decdd033067f085e24c919d27e07cacfa4
MATLAB
49,915
822
%% Neurofeedback: comparisons between conditioned and control animals animals = {'jaq','roquefort','despereaux','montague','remy','gus','bernard','fievel'}; epochfilter{1} = ['(isequal($cond_phase,''pre'') | isequal($cond_phase,''early'') ) & (isequal($environment,''goal'')| isequal($environment,''hybrid2'') | isequ...
e1ec6830da6c9691f2ea721d4181992c8f61328fb57ca75ec1c12bdc6ccf1e0c
MATLAB
49,920
1,217
% Match detections between consecutive frames. % % To match detections, use: % % trks = track_match(detections, calib, [chamber_str]) % % where: % % detections - detections obtained from track_detect % calib - calibration obtained from calibrator or tracker_job_calibrate % chamber_str ...
80227694c9abd10ed621678e5ccf70e430225de0a00fc502e539a827fbdbc8ea
MATLAB
50,054
962
% This script checks for operational errors in the functions of this package lasterror ('reset'); try % boot boot (3, 20); boot (3, 20, false, 1); boot (3, 20, true, 1); boot (3, 20, [], 1); boot (3, 20, true, 1, [30,30,0]); % bootknife % bootknife:test:1 y = randn (20,1); strata = [1;1;1;1;1;...
d22fbd1420f20756a125e7da712a240053d68393482ae30d2566a613b3570e81
MATLAB
51,266
1,495
% Function File: eventer % % peak = eventer(file,TC,s,SF) % peak = eventer(file,TC,s,SF,...,'exclude',exclude) % peak = eventer(file,TC,s,SF,...,'criterion',criterion) % peak = eventer(file,TC,s,SF,...,'rmin',rmin) % peak = eventer(file,TC,s,SF,...,'hpf',hpf) % peak = eventer(file,TC,s,SF,...,'lpf',lpf) % peak ...
2cb80c46506eedf05a7918e68f3e491be68b9f22b734513aab440230840cf5b0
MATLAB
51,802
2,182
function atlas = ft_read_atlas(filename, varargin) % FT_READ_ATLAS reads an template/individual segmentation or parcellation % from disk. The volumetric segmentation or the surface-based parcellation % can either represent a template atlas (eg. AAL or the Talairach Daemon), % it can represent an individualized atlas (...
1070bda22cc256dc00bc425c68c9e71828736f1b51e13cbb577890fe150c4550
MATLAB
52,362
1,034
%% Prompt User for Variables clear;clc;close all warning off prompt = {'Path: ', 'R^2 Threshold: ', 'Bad Segment Count: ', 'Removed Data Percentage: ', 'Gain Type (1 = norm, 2 = raw}', 'Training Block Size (5 or 10 minute, 1 for OKR)'}; dlgTitle = "Input: "; dims = [1 40]; definput = {'F:\1 Jaydev Bhateja\Cohort 4\Data...
9c2cf34431fdeec95aef9f528c4eb4bfa9bce8bf5ff760b06a2fcfa817c2ef69
MATLAB
52,561
1,264
function param = ExtractSimilarityMetrics(Scores2Include,AllWVBParameters,clusinfo,param,drawthis) anglecorr = 0; % Cross tested, 0 seems best UseFlipCombis = 0; % Cross tested, 0 seems best %% Extract fields and parameters ExtractFields({AllWVBParameters}) waveidx = param.waveidx; Allchannelpos = param.AllChannelPos...
ae80ab290a4123c177567bae54c4dcc8571cf03a2659c70b1ec95293da20dfea
MATLAB
52,580
818
% DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT % Name: ChemoSLA_DataExtraction % Cohort: NAc dLight1.3b with chemogenetic inhibition and temporal window % Sep 2023 - Marie Labouesse, marie.labouesse@gmail.com % extracts FP data (select folder from a particular day eg day 1, containing multiple animals...
1323f0f7669c6983a17b994c32dd70237130cdd9a27ebd32d4333426074782e7
MATLAB
52,618
1,278
%% Script that is a variation of the stats script that gets the information for individual hypoxic events % Antonis Asiminas, PhD % Center for Translational Neuromedicine % University of Copenhagen, 28 Sep 2023 % Last updated 9 July 2024 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% (1) Load the file with ...
8f62cabe1e0a82d996b8f3402012b739e1b12d7d89b1b67f24b9e2735a723b10
MATLAB
52,742
819
% DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT % Name: WeeklyDETQ_SLA_DataExtraction % Cohort: NAc dLight1.3b with chemogenetic inhibition and temporal window< % or effect of food restriction % Sep 2023 - Marie Labouesse, marie.labouesse@gmail.com % extracts FP data (select folder from a particular d...
721dd6f189915cb39d6608f12d588b1f59f480d5493a077cc70434791c24a6de
MATLAB
52,773
1,511
function GUI_refine(video,folder,masks,update_result) % global video; % global masks; % global Lx; % global Ly; % global T; % global N; global thred_IoU; global thred_IoU_split; global thred_jaccard_inclass; global thred_jaccard; global auto_on; % global variables calculated outside the GUI global list_weight; % globa...
98122ac8989546d8bbabdcdc2bc0b6e28a043f4bf1734a2983caf7a302f5e263
MATLAB
53,128
1,524
%Training Script Enny van Beest for Mice: EasyLickTask. Start with %water-restriction. Habituation %to head-restriction before start training. % Moving Stim is rewarded (80%) and still stim is not rewarded (20%) % (eventually, but first trai n on 100% moving) %% Manual User Settings ProcMoving = 100; %Moving stimulus ...
6bef13cc88ea2a2d376daec25ea5b8b498ea63ed71b7dfdb756067296b0875c6
MATLAB
53,891
1,562
% Function File: eventer % % peak = eventer(file,TC,s,SF) % peak = eventer(file,TC,s,SF,...,'method',method) % peak = eventer(file,TC,s,SF,...,'exclude',exclude) % peak = eventer(file,TC,s,SF,...,'criterion',criterion) % peak = eventer(file,TC,s,SF,...,'rmin',rmin) % peak = eventer(file,TC,s,SF,...,'hpf',hpf) % ...
fc208f9cd4090995bbf1458963ae60a56528554ed854315daf1dadd272a87d9f
MATLAB
54,376
1,447
function [d,si,h]=abfload(fn,varargin) % ** function [d,si,h]=abfload(fn,varargin) % loads and returns data in ABF (Axon Binary File) format. % Data may have been acquired in the following modes: % (1) event-driven variable-length (currently only abf versions < 2.0) % (2) event-driven fixed-length or waveform-fi...
bbf24370d6e687ad08ed1ed6fb16e16b153d9fbd83d6482ee5b7bdf907c89911
MATLAB
54,643
1,457
function [d,si,h]=abfload(fn,varargin) % ** function [d,si,h]=abfload(fn,varargin) % loads and returns data in ABF (Axon Binary File) format. % Data may have been acquired in the following modes: % (1) event-driven variable-length (currently only abf versions < 2.0) % (2) event-driven fixed-length or waveform-fixe...
d1bbf6ac8bd6f90f98aa5052039687fe3da792b8337db2b61389fdd7ecbc09d8
MATLAB
55,149
1,289
function [matData, meta, nseries, tree, stimTree]=ImportHEKA(thisfile, targetpath) % ImportHEKA imports HEKA PatchMaster and ChartMaster .DAT files % % Example: % OUTPUTFILE=ImportHEKA(FILENAME) % OUTPUTFILE=ImportHEKA(FILENAME, TARGETPATH) % % FILENAME is the path and name of the HEKA DAT file to import. % % The kcl f...
bc5e7662be001968a1e2988707b076689e6c31bc225c356ba44bba3527a58c20
MATLAB
55,502
1,092
classdef NWBFile < types.core.NWBContainer & types.untyped.GroupClass % NWBFILE An NWB file storing cellular-based neurophysiology data from a single experimental session. % READONLY PROPERTIES properties(SetAccess = protected) nwb_version; % (char) File version string. Use semantic versioning, e.g. 1.2.1. This ...
499a433f2c0d013f5218a442899c91613e03dc0ad539ac093daac8dec277362a
MATLAB
55,686
1,061
% CLEAN_DATA_WITH_ZAPLINE_PLUS - Removial of frequency artifacts using ZapLine to remove noise from EEG/MEG data. Adds % automatic detection of the noise frequencies, chunks the data into segments to account for nonstationarities, detects % the appropriate number of removed components per chunk, based on the individual...
efee0d5da0c22a87a0dd7516623a4f9b69cb97f034fce8d7ba3a154b85448469
MATLAB
55,795
1,382
function [dat] = ft_read_data(filename, varargin) % FT_READ_DATA reads electrophysiological data from a variety of EEG, MEG and LFP % files and represents it in a common data-independent format. The supported formats % are listed in the accompanying FT_READ_HEADER function. % % Use as % dat = ft_read_data(filename, ...
85e6384565a2d9a8be037cde92ca5d3bab0bedd3d4a5f70092218ca3bfffd371
MATLAB
55,962
1,281
% sdfopen() - Opens EDF/GDF/SDF files for reading and writing. The EDF format is specified % in [1], GDF in [2]. SDF is the SIESTA convention (see [3], pp.8-9); SDF uses % the EDF format. % Usage: % >> EDF = sdfopen(Filename,'r' [,CHAN]); % prepare to read CHAN channels % >> E...
f74ee8be3ce3bab535cadba60e8485d3f5ed908a23283cb1f11be9b912122f76
MATLAB
56,488
1,089
% computes corr instead of tunings % uses the structs and functions of tune and tuning, but saves them corr % uses unitsTable while running, but saves the data in: % - unitsTable (mat and xlsx) if UPDATE_unitsTable==1 % - corrTable (mat and xlsx) if UPDATE_corrTable==1 % generates and use shuffled data: % ...
2d187f8c4296b45b97b78554b4292f42d06126fefdaf689722236838963ed6ec
MATLAB
57,437
1,121
function [HDR]=scpopen(arg1,CHAN,arg4,arg5,arg6) % SCPOPEN reads and writes SCP-ECG files % % SCPOPEN is an auxillary function to SOPEN for % opening of SCP-ECG files for reading ECG waveform data % % Use SOPEN instead of SCPOPEN % % See also: fopen, SOPEN, % $Id: scpopen.m 8776 2013-11-14 09:04:48Z roboos $ %...
6e40a4cf6232b6f7517dd8abd74258b52253d7c35f416d8e079e6e4075cb5253
MATLAB
57,503
1,868
% mglSetSID.m % % $Id:$ % usage: mglSetSID() % by: justin gardner % date: 04/20/14 % purpose: Sets the subject ID which is used by initScreen % and mglTaskLog. Subject ID is then retrieved with % mglGetSID % % To set a known SID: % mglSetSID(...
90c051b4ce32abc533381193061c6024df38fc0b10a202020693ab8864a7d01a
MATLAB
58,340
1,358
function [h,yy,zz] = arrow(varargin) % ARROW Draw a line with an arrowhead. % % ARROW(Start,Stop) draws a line with an arrow from Start to Stop (points % should be vectors of length 2 or 3, or matrices with 2 or 3 % columns), and returns the graphics handle of the arrow(s). % % ARROW uses the mouse (cl...
fcfeca667f6619d5f47bb1fdf89b05a225f11337423378b273c99545d57f4102
MATLAB
58,889
1,523
function [d,si,h]=abfload(fn,varargin) % ** function [d,si,h]=abfload(fn,varargin) % loads and returns data in ABF (Axon Binary File) format. % Data may have been acquired in the following modes: % (1) event-driven variable-length (currently only abf versions < 2.0) % (2) event-driven fixed-length or waveform-fi...
00aa17742880da08341761b60f4aaf217ec1a2ce32ee1b91915f77334fd69535
MATLAB
59,576
1,566
function [d,si,h]=abfload(fn,varargin) % ** function [d,si,h]=abfload(fn,varargin) % loads and returns data in ABF (Axon Binary File) format. % Data may have been acquired in the following modes: % (1) event-driven variable-length (currently only abf versions < 2.0) % (2) event-driven fixed-length or waveform-fixe...
b0bb1c3fe1cc16d617dbdd68268fbe06945a521e8b1fe724776be11ed9ce96ec
MATLAB
60,799
1,865
function [DATA,msg_out] = aedes_readfid(filename,varargin) % AEDES_READFID - Read VNMR (Varian) FID-files % % % Synopsis: % [DATA,msg]=aedes_readfid(filename,'PropertyName1',value1,'PropertyName2',value2,...) % [DATA,msg]=aedes_readfid(filename,'header') % [DATA,msg]=aedes_readfid(filename,out...
08b7af8e3c1ce4451f5c078b5f9989e58e80fcdf88740330210ecd97c9a45d43
MATLAB
61,516
966
% DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT: % Name: Shock_DataExtraction % First creation Sept 2020; Updates for Zurich May 2021, August 2021, March % 2023, March 2024 % Marie Labouesse, marie.labouesse@gmail.com % Cohort: dLight1.3b or GCAMP with shock % extracts FP data (select folder from a pa...
70679ea4ed1f62734a90caf3a8ddb55a5570ecf34a579515287ade79764d0dab
MATLAB
61,538
964
% DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT: % Name: Shock_DataExtraction % First creation Sept 2020; Updates for Zurich May 2021, August 2021, March 2023 % Marie Labouesse, marie.labouesse@gmail.com % Cohort: PFC dLight1.3b with shock % extracts FP data (select folder from a particular day eg day ...
63f5a7ccfbf27b2bd091933812c27672f6a21d7aa6a1f70493c604c3317fdbfe
MATLAB
61,892
1,756
% Obtain tracking parameters via user input. % % To start the calibration, use: % % success = calibrator(f_vid, f_info) % % where: % success - indicates wheter calibration was completed % f_vid - path of input video % f_calib - path to which calibration file will be saved % function suc...
73acfe85af892a8bba63c1f0f5d1b34bc91af89dc83edd878e10211f07b7a505
MATLAB
62,399
1,059
% computes corr instead of tunings % uses the structs and functions of tune and tuning, but saves them corr % uses unitsTable while running, but saves the data in: % - unitsTable (mat and xlsx) if UPDATE_unitsTable==1 % - corrTable (mat and xlsx) if UPDATE_corrTable==1 % generates and use shuffled data: % ...
0f2295b975c57d2608d09d3df39fbe6919546d8863c7a4613f614f2e3636ae10
MATLAB
63,157
1,375
function [type] = ft_filetype(filename, desired, varargin) % FT_FILETYPE determines the filetype of many EEG/MEG/MRI data files by % looking at the name, extension and optionally (part of) its contents. % It tries to determine the global type of file (which usually % corresponds to the manufacturer, the recording syst...
6430f2f8439b451749839c8d37dff95dc8a6530b0749ffc0d025393842b1a577
MATLAB
64,715
1,553
% runica() - Perform Independent Component Analysis (ICA) decomposition % of input data using the logistic infomax ICA algorithm of % Bell & Sejnowski (1995) with the natural gradient feature % of Amari, Cichocki & Yang, or optionally the extended-ICA % algorithm of Lee, G...
4481ba03d4d8f95b04b8c0c598d87592374b7b06f27d8a8af6f74d81bdb3429e
MATLAB
65,507
1,331
function [HDR] = getfiletype(arg1) % GETFILETYPE get file type % % HDR = getfiletype(Filename); % HDR = getfiletype(HDR.FileName); % % HDR is the Header struct and contains stuff used by SOPEN. % HDR.TYPE identifies the type of the file [1,2]. % % see also: SOPEN % % Reference(s): % [1] http://pub.ist.ac.at/~sch...
53dd38f719a2cfdd8a582428616f9ab4d5674097e086a593428b85f496a355be
MATLAB
66,390
1,619
% mglRetinotopy.m % % $Id$ % usage: mglRetinotopy(varargin) % by: justin gardner % date: 04/06/07 % copyright: (c) 2007 Justin Gardner (GPL see mgl/COPYING) % purpose: Displays a retinotopy stimulus, there are many % parameters you can set, you can set as many % or ...
cd33addf02df98ad5145ae4f90f02ff02db9944166f42dbdab0595250ab763e2
MATLAB
66,462
992
%% Neurofeedback: main analyses. Plateau phase only animals = {'remy','gus','bernard','fievel'}; %epochfilter{1} = ['isequal($cond_phase,''pre'') & (isequal($environment,''goal'') | isequal($environment,''hybrid2'') | isequal($environment,''hybrid3'')) ']; %epochfilter{2} = ['isequal($cond_phase,''early'') & (isequ...
553fe012b1899651add6298b43ce47d353c033e9ff1d0f0e1096162ab53d136a
MATLAB
66,752
1,002
%% Neurofeedback: full timecourse animals = {'remy','gus','bernard','fievel'}; epochfilter{1} = ['isequal($cond_phase,''pre'') & (isequal($environment,''goal'') | isequal($environment,''hybrid2'') | isequal($environment,''hybrid3'')) ']; epochfilter{2} = ['isequal($cond_phase,''early'') & (isequal($environment,''goa...
6f926bdd6536462afab3f78e58d01b1bf0cbaaa07a7fa824886e73c37d460b1e
MATLAB
67,788
1,563
function [S,HDR,time] = sread(HDR,NoS,StartPos) % SREAD loads selected segments of signal file % % [S,HDR] = sread(HDR [,NoS [,StartPos]] ) % NoS Number of seconds, default = 1 (second) % StartPos Starting position, if not provided the following data is read continously from the file. % no re...
268bb63bfbf8b3257edc50bd5caa894fea2581a4556e553177adce0287b150ed
MATLAB
67,970
1,652
% mglRetinotopy.m % % $Id$ % usage: mglRetinotopy(varargin) % by: justin gardner % date: 04/06/07 % copyright: (c) 2007 Justin Gardner (GPL see mgl/COPYING) % purpose: Displays a retinotopy stimulus, there are many % parameters you can set, you can set as many % or ...
443f2b9aebf3484dd0f98d4f687f761c8a9fde5a79d6b3439a928a99d935d4f7
MATLAB
68,255
1,352
classdef MLCalciumImagingPipeline < handle properties experimentParentFolder = ''; analysisParentFolder = ''; experiment = {}; verbose = true; includeOtherRoi = true; availablePerTrialTasks = { ... 'per_trial...
03594ae6f27855814fecb71efa3655d46310bd72e5d9f083a2fcb6c347230f8f
MATLAB
69,864
1,181
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
db9b3a962262ba0a212dba48f8f885d91e3c4ef0a176f9fc1b02128cc11465f5
MATLAB
70,483
1,596
function [ConvertedData,ConvertVer,ChanNames,GroupNames,ci]=convertTDMS(varargin) %Function to load LabView TDMS data file(s) into variables in the MATLAB workspace. %An *.MAT file can also be created. If called with one input, the user selects %a data file. % % TDMS format is based on information provided by Nation...
8ad25ac829762dae641518e94322f45eb3ffdbf9c1a90f859cb8b6d38a90575f
MATLAB
71,529
1,263
% computes corr instead of tunings % uses the structs and functions of tune and tuning, but saves them corr % uses unitsTable while running, but saves the data in: % - unitsTable (mat and xlsx) if UPDATE_unitsTable==1 % - corrTable (mat and xlsx) if UPDATE_corrTable==1 % generates and use shuffled data: % ...
a27a8b2923740f54da54783bed0de8203f022ef991c4ef4972f6ee795137b30d
MATLAB
72,414
1,701
% Performs one or two levels of bootknife resampling and calculates bootstrap % bias, standard errors and confidence intervals. % % -- Function File: bootknife (DATA) % -- Function File: bootknife (DATA, NBOOT) % -- Function File: bootknife (DATA, NBOOT, BOOTFUN) % -- Function File: bootknife ({D1, D2, ...}, NBOOT, BOO...
203321e99a3c7e24d8590ecf19fdc033f604bb31e4726aef74aab368aad21c3c
MATLAB
72,877
1,676
%% User-Input Scriptsdir = '\Path\To\GitHub\Scripts';% storepath = '\Path\To\Storage\' %Main storage --> Will contain all processed data & model of the brain RawDataDirectory = '\Path\To\RawImagingData\' %Raw images. DataDirectory = RawDataDirectory; %Might be different when downsampling data first miceopt = {'Faraday'...
0c2e08c1ed8c24f1e5d822acd7c40da27eade271d4bf05ae76dd438174363683
MATLAB
73,184
1,280
% computes corr instead of tunings % uses the structs and functions of tune and tuning, but saves them corr % uses unitsTable while running, but saves the data in: % - unitsTable (mat and xlsx) if UPDATE_unitsTable==1 % - corrTable (mat and xlsx) if UPDATE_corrTable==1 % generates and use shuffled data: % ...
d33c72da7e09723622dc6dfaa3dd85da0c02609ee2838bb2550ebc646c708150
MATLAB
73,322
2,330
% mglSetSID.m % % $Id:$ % usage: mglSetSID() % by: justin gardner % date: 04/20/14 % purpose: Sets the subject ID which is used by initScreen % and mglTaskLog. Subject ID is then retrieved with % mglGetSID % % To set a known SID: % mglSetSID(...
17de5c03b5b7a47cc48ef2bd82407fe968a82b43365503adf35603a7f406f6ff
MATLAB
73,789
1,484
classdef MLCalciumImagingPipeline < handle properties experimentParentFolder = ''; analysisParentFolder = ''; experiment = {}; verbose = true; includeOtherRoi = true; availablePerTrialTasks = { ... 'per_trial...
2a6696c18c5c9db88a63c63762f8c3bc95c4fcca806dff54ce76fc357ca86378
MATLAB
74,159
1,112
% DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT % Name: OptoSLA_DataExtraction % Cohort: NAc dLight1.3b with opto-inhibition (eNPHR) % May 2023 - Marie Labouesse, marie.labouesse@gmail.com % extracts FP data (select folder from a particular day eg day 1, containing multiple animals inside) % generates...
5a7df795595fce785348f1d6d734647551e6441b662d5105ad13e216d47b8416
MATLAB
76,674
1,189
% %Main script for Time-Series Analyses %Used in: % Pisanski, A., Prostebby, M., Dickson, D., Pagliardini, S. (2024). % "Mapping responses to focal injections of bicuculline in the % lateral parafacial region identifies core regions for maximal generation % of active expiration" %Requires Functions: % L...
afb65cba29af968d417a5cb7dd9635b94b7ac75c53245ba184fcc85c4a37da5e
MATLAB
77,147
2,112
classdef EMCM < handle % EMCM (Eigen Manifold Cross Mapping) Class for eigen time delaying % time series as high dimensional manifolds and assessing how well % they predict each other. % This class is able to get two time-series, embed them in higher % dimensional attractors, and apply cross-ma...
56c6b7efc7cbd122266c2528c10d4596963444575f4faff118624dc9ef8a560a
MATLAB
77,148
2,112
classdef EMCM < handle % EMCM (Eigen Manifold Cross Mapping) Class for eigen time delaying % time-series as high dimensional manifolds and assessing how well % they predict each other. % This class is able to get two time-series, embed them in higher- % dimensional attractors, and apply cross-m...
544fbc69b84c845f8a04c9d893538472e8e72d480ebf1ae6accbd27bb9772a43
MATLAB
77,339
1,952
function varargout = spm_orthviews(action,varargin) % Display Orthogonal Views of a Normalized Image % FORMAT H = spm_orthviews('Image',filename[,position]) % filename - name of image to display % area - position of image % - area(1) - position x % - area(2) - position y % - area...
edc3b930b9762ee58c0f049e12752395f9a1448480b668ddfe139dd4dc627999
MATLAB
77,665
2,220
function [data] = ft_checkdata(data, varargin) % FT_CHECKDATA checks the input data of the main FieldTrip functions, e.g. whether % the type of data strucure corresponds with the required data. If neccessary % and possible, this function will adjust the data structure to the input % requirements (e.g. change dimord, a...
3b13eea4b0cde25e57f917034cd32296f92402ee6bfa7a24a252dfb39ba25ab7
MATLAB
77,823
1,436
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% %clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
ea870090ff262ab19deda7e1d887c6144559379f6f40ce95ce768b36e8e56ff4
MATLAB
77,915
1,900
function [event] = ft_read_event(filename, varargin) % FT_READ_EVENT reads all events from an EEG/MEG dataset and returns % them in a well defined structure. It is a wrapper around different % EEG/MEG file importers, directly supported formats are CTF, Neuromag, % EEP, BrainVision, Neuroscan and Neuralynx. % % Use as ...
294fdc74a2123d551d5a89bdaac36330a48959d66359fcb3ccf17cf7047eb423
MATLAB
82,338
1,271
% DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT % Name: CocaineNAc_DataExtraction % Cohort: NAc AllodLight-ctrl with opto and drugs (DETQ, cocaine) % Feb 2023 - Marie Labouesse, marie.labouesse@gmail.com % extracts FP data (select folder from a particular day eg day 1 vs. day2, containing multiple anim...
b3091db32c7e213592dba2fde3fc0a76edb37c698e884d390540c20baf15e901
MATLAB
82,854
2,182
%% Working Memory Trainin g + Opto + Imaging Script %Training Script Enny van Beest for Mice: Working memory. Start %wa ter-restriction. Habituation %to head -restriction before start training. %Increase level of paradigm pvo (motor) l ickspout. At the end of an %imaging session, passive licker mouse. This script has 5...
cd36ac0a6e44f0917f1a6a481b69cea2b9ad23db288366ab4610a24081492fda
MATLAB
83,477
1,382
% OptoDoseResponse_PooledGraphs_2023 % DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT % Name: OptoDoseResponse_PooledGraphs_2023 % Cohort: PFC dLight1.3b with opto % May 2023 - Marie Labouesse, marie.labouesse@gmail.com % 1- POOLED GRAPHS % loads FP data previously analyzed (with: OptoDoseResponse_...
035d25dc29dea40616d8e638a1dec985f1a87af0a025c0be1185784b0ced2e02
MATLAB
83,864
1,412
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% %clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
8f581ec1531c802ed152d0631495bd4795114da1e6303b5ce42a15b91c54aeab
MATLAB
84,567
1,427
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'singl...
3788d89ffc4bb6249838901c026e1a03522fa15c69927d451e8933f7f8988595
MATLAB
85,433
2,489
% legTracksAnalysisScript.m % % Quick and dirty script for starting to look at leg tracking data % % various cells are things tried % % 8/5/21 - HHY %% analysis constants % indicies for specific body parts % fit line to head and 3 pts defining midpt b/w legs refPts.lineFitInd = 7:10; refPts.midPtInd = 9; refPts.headP...
58685d11354371b98e644c4a0b792b6bdfdbe55e0761b561ac0ddcd7f7deba77
MATLAB
85,641
1,448
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. % modified again by ehud, Jan 2019, to process the new structs (39-49) % TODO % 1. Nuu=262, unitsTable length=142 % 2. check tuning, with discontinuous movies %% ...
3a44b42729346e7d1f6afc2b7f649bc2813bc5dbd8c48df848987018937ec0b4
MATLAB
85,837
1,444
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'singl...
5d987228ecc309c38f73b08cf4f5515101617251a3c9d92e5d6bed4c9466471a
MATLAB
86,777
2,731
% Function File: ephysIO % % USAGE: To save a column-major XY array of electrophysiology data: % ephysIO (filename,array,xunit,yunit,names,notes,datatype) % % To load column-major XY array of electrophysiology data: % data = ephysIO (filename) % [array,xdiff,xunit,yunit,names,not...
d61f2de0301d36c4188cb335e6a5d1f5bac5090cc62f63023c028dab1546bd5c
MATLAB
87,499
2,217
function [hdr] = ft_read_header(filename, varargin) % FT_READ_HEADER reads header information from a variety of EEG, MEG and LFP % files and represents the header information in a common data-independent % format. The supported formats are listed below. % % Use as % hdr = ft_read_header(filename, ...) % % Additional...
b7f517342e4743d55ce63bb757b5ef875e55ab65cd32638bdbfd6ec49f0107f8
MATLAB
88,401
1,477
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% %clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
18728c951c43dce8d7390f9625c6d2f17550fb17c6257f4ea28ec78cf33ac0e1
MATLAB
89,304
2,372
function varargout = spm_input(varargin) % Comprehensive graphical and command line input function % FORMATs (given in Programmers Help) %_______________________________________________________________________ % % spm_input handles most forms of interactive user input for SPM. % (File selection is handled by spm_select...
7f5be23c4fc3c863374b461f0c1496f52dfa4ce38273cc5f5dd75b7ae330d5df
MATLAB
89,427
2,626
% moncalib.m % % usage: To run a calibration: % calib = moncalib; % % To display a previously run calibration % moncalib(calib); % % Options that you can use: % calib = moncalib('numRepeats=4','stepsize=1/256',... % numRepeats = number of r...
b583f49c6a8c50ea66bba01ab45a81eaa76e85430db8b80141deac0bfd7d5010
MATLAB
89,446
1,528
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% %clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
6504696e6b65c4063545a58a1465d975403eb48708d76f8d6f321ad03773c8a4
MATLAB
89,514
3,694
function label = ft_senslabel(type, varargin) % FT_SENSLABEL returns a list of predefined sensor labels given the % EEG or MEG system type which can be used to detect the type of data. % % Use as % label = ft_senslabel(type) % % The input sensor array type can be any of the following % 'ant128' % 'biosemi64' % 'bi...
49839c673f920ee67c758cd62d1aa5aab9ca54e8bc967a20eb7905634eedca8f
MATLAB
89,647
2,175
classdef Sources2D < handle % This class is a wrapper of Constrained NMF for standard 2D data. It % Both CNMF and CNMF-E model can be used. % Author: Pengcheng Zhou, Columbia University, 2017 % zhoupc1988@gmail.com %% properties properties % spatial A; % s...
7a3deae9d20733c2d8d2ccd629e7a4bf3a79cef3a0f029120d414a98fb4e76a6
MATLAB
90,267
1,429
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'singl...
89e7aa86d4b85c450c842bb970892b8371dce7c81e92cc677961e178e43d8c13
MATLAB
90,337
2,852
function varargout = labelerrorsgui(varargin) % TRX = LABELERRORSGUI(SEQS,MOVIENAME,TRX,ANNNAME,PARAMS,[LOADNAME]) % SEQS: array of suspicious sequences % MOVIENAME: name of movie % TRX: positions of flies over time % ANNNAME: name of annotation file % PARAMS: parameters used to determine suspicious sequences % LOADNAM...
417d22ea684e0302d21844d5a7d2b7068408d337cd1a3be19fe7a9b13c63ad00
MATLAB
91,010
1,533
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% %clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
30db75052dbb2f158111b60ade0de8ac2136d8c16635e58979fbbe4d7d6b2c51
MATLAB
91,458
1,534
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% %clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
108f6ca72ce35b7af4738979a50508a5430d0ed430f1e222e9167b79a96f4759
MATLAB
91,631
2,666
% moncalib.m % % usage: To run a calibration: % calib = moncalib; % % To display a previously run calibration % moncalib(calib); % % Options that you can use: % calib = moncalib('numRepeats=4','stepsize=1/256',... % numRepeats = number of r...
c5ffb991b113fb7c07d1ede35f46084a16eb72733665f7bfb6959a806d7ef310
MATLAB
93,952
1,414
% DATA ANALYSIS PIPELINE FOR FIBER PHOTOMETRY EXPERIMENT % Name: OptoDoseResponse_DataExtraction % Cohort: PFC dLight1.3b with opto-dose response and temporal window % May 2023 - Marie Labouesse, marie.labouesse@gmail.com % extracts FP data (select folder from a particular day eg day 1, containing multiple anim...
9d37e57480ee82cb7705a8053ddd8c9e7177c831200037402caf7157c564a56d
MATLAB
94,115
2,178
function varargout=spm_conman(varargin) % Contrast manager: GUI for defining valid contrasts % FORMAT varargout=spm_conman(varargin) % - An embedded callback, multi-function function % - For detailed programmers comments, % see format specifications in main body of program (below user help) %_______...
9360794e839cd44fe47adf5b3d2ba3b0b034e96b9154c77c2c9198fea57887d9
MATLAB
94,245
1,592
% presents response maps in units of spikes/paired-event. arrange selected % cells from all sessions together %modified from amapOF Oct 2016, ehud. %% %clear all; runMode = 'single'; % leave when running this script. comment out when running a batch from runAmapOF %% globals; switch runMode, case 'sing...
c4660ae33d67bebc4aeedeade0dd024727d1ac6de1db50bccd1f4f38752e6d93
MATLAB
95,289
2,832
function varargout = fixerrorsgui(varargin) % TRX = FIXERRORSGUI(SEQS,MOVIENAME,TRX,ANNNAME,PARAMS,[LOADNAME]) % SEQS: array of suspicious sequences % MOVIENAME: name of movie % TRX: positions of flies over time % ANNNAME: name of annotation file % PARAMS: parameters used to determine suspicious sequences % LOADNAME: p...
398e277ee8f28098bed819f1fa6e3dd2f0e71a5f3eedbc25ec2f1f882c34b01e
MATLAB
97,407
1,491
function [lambda, xFcn, yFcn, zFcn] = mglColorMatchingFunctions(formulary) % % % %colorMatchFcn Popular color matching functions. % % [LAMBDA, XFCN, YFCN, ZFCN] = colorMatchFcn(FORMULARY) returns the % color matching functions XFCN, YFCN, and ZFCN at each wavelength in % the vector LAMBDA. FORMULARY is a s...
549a8203a35c69908e9a32df31d50f516443b8bef460d7bc93d6074fc63b6500
MATLAB
98,859
2,310
datapath = '\Path\To\Data\'; AllMice2Use = {'Alaska','Becquerel','Berlin','Cherry','China','Darwin','Druif','Faraday','Galilei','Grape','Haydn','Holland','HongKong','Jemison','Jenkins','Joule','Karlsen','Kirchoff','Leeuwenhoek','Lully','Ising','Mahler'}; Gentype = {'Control','D2','D2','D1','D1','Control','Control','D2'...
b1144897688946edc0ca2d24be2026b795fcf67ff779bd3a5e393e4138a69c70
MATLAB
107,942
2,374
% Empirical Bayes penalized regression for univariate or multivariate outcomes, % with shrinkage tuned to minimize prediction error computed by .632 bootstrap. % % -- Function File: bootridge (Y, X) % -- Function File: bootridge (Y, X, CATEGOR) % -- Function File: bootridge (Y, X, CATEGOR, NBOOT) % -- Function File: b...
0cac6cadd574e5c05acb0b27bbe90e181dfb348b396f898fc1b825fc452b6004
MATLAB
112,912
3,412
% Function File: ephysIO % % USAGE: To save a column-major XY array of electrophysiology data: % ephysIO (filename,array,xunit,yunit,names,notes,datatype) % % To load column-major XY array of electrophysiology data: % data = ephysIO (filename) % [array,xdiff,xunit,yunit,names,not...
8f176d6afed70950c7d891ddb8538dbb6fb69c125cdd0fefffa0d2481f5bc8d8
MATLAB
113,530
3,423
% Function File: ephysIO % % USAGE: To save a column-major XY array of electrophysiology data: % ephysIO (filename,array,xunit,yunit,names,notes,datatype) % % To load column-major XY array of electrophysiology data: % data = ephysIO (filename) % [array,xdiff,xunit,yunit,names,not...
b5f96380b5470a08ec7c812e93bf5272e1a0725f9b76e3088984000bed64c829
MATLAB
115,015
2,087
%% Neural differences between young and older adults in automatic and conscious auditory predictive coding (using musical sequences) %% Maxfilter %OBS! before running maxfilter you need to close matlab, open the terminal and write: 'use anaconda', then open matlab and run maxfilter script maxfilter_path = '/neuro/bi...
2eb789b35dc7f0c77e18922469295e52c6a32397c34d68d20c6aac0a7f39d48b
MATLAB
120,384
2,792
function varargout = OtherFunction(varargin) % OTHERFUNCTION MATLAB code for OtherFunction.fig % OTHERFUNCTION, by itself, creates a new OTHERFUNCTION or raises the existing % singleton*. % % H = OTHERFUNCTION returns the handle to a new OTHERFUNCTION or the handle to % the existing singleton*. % % ...
3dbe9abdf9bc49c6e582a49441a086a624cccfae525eca60ca1834154b6d41bf
MATLAB
122,632
2,942
% p_HFOAnalysisTool.m % [As a part of HFO Detection Project] % Intrface for visualization and classification of putative HFO events % Written by: % Miguel G. Navarrete Mejia % Electrical Engineering MS. % UNIVERSIDAD DE LOS ANDES % Colombia, 2012 % mnavarretem@gmail.com % % Copyright (C) 2015...
7503a37d1a467eb8c8860dcf2c67d2118fc83682affc510e365f916a8bf5e575
MATLAB
123,149
2,461
classdef MLCalciumImagingPipeline_v1 < handle properties experimentParentFolder = ''; analysisParentFolder = ''; experiment = {}; verbose = true; includeOtherRoi = true; trackerParams = {}; availableTasks = {'phase_1', '...
7e35fdad12df673a686f0ea9c2d69f86a78826e720768d4a31f88ef73b1a8d92
MATLAB
123,871
3,305
% Visualize tracked videos, correct identities, and annotate behavior. % % To run interface, use: % % visualizer % function visualizer() % files files.video_dir = '.'; % default video directory parentdir = fileparts(mfilename('fullpath')); defpath = fullfile(parentdir,'actio...