sha256 stringlengths 64 64 | language stringclasses 28
values | size int32 1 491k | lines int32 1 23.2k | content stringlengths 1 200k |
|---|---|---|---|---|
6bbf5a7d48e7187b46beace433a05b085616ebf66233ef9aee0828076f272b22 | MATLAB | 13,523 | 375 | % io_CSIload_twix.m
% Brenden Kadota, Jamie Near, Sunnybrook 2021.
%
% USAGE:
% out = io_CSIload_twix('filename');
% out = io_CSIload_twix(scan_number);
%
% DESCRIPTION:
% Reads in siemens twix raw data (.dat file) using the mapVBVD.m and
% twix_map_obj.m functions from Philipp Ehses (philipp.ehses@tuebingen.mpg.de).
%... |
5e87c7614c01fbd7d9069f58283783fc7f2a564d58f4bc75e64993b3a295d3a1 | MATLAB | 13,535 | 395 | function [k, numItems] = txtmenu(varargin)
%TXTMENU Generate an ASCII text list menu in the command window.
% CHOICE = TXTMENU('HEADER', DESC0, DESC1, DESC2, ..., DESCn) displays a
% list of possible choices and descriptions,
%
% ----- HEADER -----
%
% >> 0) DESC0
% 1) DESC1
% ... |
1e10189ce6ff6fc302a79db87ea8650b7002070a6892594d5ced185943faa87b | MATLAB | 13,551 | 388 | classdef TDEV < handle
%TDEV TDevAccX wrapper
% obj = TDEV() connects to Workbench server
%
% obj.TD TDevAccX object
%
% obj = TDEV('parameter',value,...)
%
% 'parameter', value pairs
% 'SERVER' string, data tank server (default 'Local')
% 'VERBOSE... |
fc3d94d8e8146484109f01fd61aeb54f7ad2c0fc121badc00abefada573f72ff | MATLAB | 13,552 | 263 | % Figure03.m
% Plots for Figure 3A-C in manuscript.
% The same approach is for Supplementary Figures S02 and S08.
%
% EEG/fMRI STUDY, DONDERS INSTITUTE, NIJMEGEN.
% J. Algermissen, 2018-2023.
% Should work in Matlab 2018b.
% we are here:
% cd /project/3017042.02/Analyses/FiguresOutcomeLocked
% clear all; close all; ... |
8279440b841141fb0866cdf9efe8f6db90a5c8469ebae3023cb252a588e6ef4b | MATLAB | 13,567 | 381 | classdef (Abstract) ProcessedImg < Processable & IRawImg
%ProcessedImg - Superclass for processed image classes
%
% The ProcessedImg class is an abstract superclass that implements (or
% requires implementation in its subclasses via abstract methods or
% properties) most functionality related to processable image... |
d29280de30fb3845d7a8c111f42c23e3a9d4259b4050004b9b5822fd53827d92 | MATLAB | 13,574 | 342 | % GETTING STARTED WITH REGRESSION
%
% This is the go-to tutorial if you are new to the toolbox and want to
% get started with regression. It covers the following topics:
%
% (1) Loading example data
% (2) Regression with cross-validation and explanation of the cfg struct
% (3) Plotting results
% (4) Compare Ridge, Ker... |
4372a5713c63ab7726f296f7be3866629a5d2423a64ab322b2141242dba6c0a2 | MATLAB | 13,575 | 423 | clear
clc
%% set path
addpath('...\fcn')
addpath(genpath('...\ext'))
%% set directories
data_dir = '...\mammals_connectome';
out_dir = '...\output';
%% load data and set parameters
thresholds = {'0' '0.05' '0.1' '0.15'};
curr_thresh = 1;
load(fullfile(data_dir,...
sprintf('cents_repani_sta... |
6e296b6377db5799ce5e8f3f68f930a4b7c8df9788535b98c709db8813159fad | MATLAB | 13,582 | 468 | % mv_classify unit test
rng(42)
tol = 10e-10;
mf = mfilename;
% In the first part we will replicate behaviour of the other high-level
% functions (mv_classify_across_time, mv_classify_timextime,
% mv_crossvalidate, mv_searchlight) and compare their output to mv_classify
% output
nsamples = 100;
nfeatures = 10;
nclas... |
c618e3f858b07436c0545e5c1b90ca770ba58aa9be24cd0942102aba78ce4eaa | MATLAB | 13,602 | 242 | function interRunShift = ConcatenateExptRuns(expt, runInfo, catInfo, varargin )
IP = inputParser;
addRequired( IP, 'expt', @isstruct )
addRequired( IP, 'runInfo', @isstruct )
addRequired( IP, 'catInfo', @isstruct )
addParameter( IP, 'minInt', 1000, @isnumeric )
addParameter( IP, 'maxEdge', [100, 100, 120, 120], @... |
853be8aeb99e89a2523540946178934add64650efae1240cd33abbad587ffcd7 | MATLAB | 13,606 | 262 | % FigureS02.m
% Plots for Supplementary Figure S02.
% The same approach is used for Figure 3 and for Supplementary Figures S08.
%
% EEG/fMRI STUDY, DONDERS INSTITUTE, NIJMEGEN.
% J. Algermissen, 2018-2023.
% Should work in Matlab 2018b.
% we are here:
% cd /project/3017042.02/Analyses/FiguresOutcomeLocked
% clear al... |
eac0920f70326bc48da82da74b2a2f1f1d76d4c14e572c701b43ea52662631d7 | MATLAB | 13,662 | 345 | classdef DataFindROIsCellSort < DataFindROIs
%DataFindROIsCellSort - Data from stICA-based ROI identification
%
% The DataFindROIsCellSort class contains the data generated by
% CalcFindROIsCellSort.
%
% DataFindROIsCellSort public properties inherited from Data:
% mask - A mask combining all of the ot... |
d160a342b7fdb0e5279eefd17817de72729e7ab7e4065a27a744bd50aaf6ba50 | MATLAB | 13,762 | 416 | % GELoad_CSI.m
% Jamie Near, Sunnybrook Research Institute 2024
% Louis Lauzon, University of Calgary 2024
%
% USAGE:
% [FullData,hdr]=GELoad_CSI(fname);
%
% DESCRIPTION:
% Reads in GE P-files (.7 file) using code adapted from nGetData_dv26.py
% and aux_get_hdr.py, both provided by Louis Lauzon.
%
% Alo reads in GE .h5... |
f22e2b01905954a8f67d63981aed8f3b68adf2b51c01508f5952e190f340db60 | MATLAB | 13,826 | 365 | clear
clc
%% set path
addpath('...\fcn')
addpath(genpath('...\ext'))
%% set directories
data_dir = '...\mammals_connectome';
out_dir = '...\output';
%% load data and set parameters
N = 200;
S = 201;
order = loadname(fullfile(data_dir, "AnimalOrder.mat"));
animal_name = loadname(fullfile(data_d... |
723540e22a793c589285d913f3aeb790402e2329d131cd98332440a4bf11b7d8 | MATLAB | 13,841 | 402 | % This code simulates the dynamics of recurrent spiking network model for
% specified AMPAR, NMDAR, and GABAR conductances and saves the spike
% trains of individual neurons in the "Simulations" subdirectory.
%
% The values of the synaptic conductances can be either loaded from the
% "Parameters" subdirect... |
9313a884c0b5048372937101e4e527952137f56bb43fbff029618be365fb4746 | MATLAB | 13,853 | 327 | function [out] = EEGfMRIPav_aggr_data()
% [out] = EEGfMRIPav_aggr_data()
%
% Loads behavioral data and
% - recodes if necessary (uninstructed key presses, too short/long RTs,
% updated accuracy)
% - recodes outcomes
% - sorts data per stimulus
% - sorts data per condition
% - creates Win-stay/lose-shift variable
% -... |
8a387a88b5c27b57e111ca179883733089362039235dee2f855021fe555858e1 | MATLAB | 13,874 | 533 | %
%this file has been made only to explore, do not run it!
clear
close all force
load('a0_0_bhv2trialStrct.mat');
load a16_0_SacProperties.mat
%}
%%
iMonkey = 1;
UMuscimol = [ 0, 12,9 ,4,1 ,14,11 ,6,3 ];
UMuscimol = [ 0, 12,9 ];
UMuscimol = [ 0, 12,9 ,4,1 ];
UMonkey = [1,3];... |
0672988854621b0ed100f5804ef23d01714accc52a5c1c7878ff87c1b0b6c169 | MATLAB | 13,878 | 244 | function [boutStack, Tbout, boutSpeed, storeFrames] = WriteBoutMovies(expt, sbxInfo, Tscan, loco, periBout, movParam, varargin) %
IP = inputParser;
addRequired( IP, 'expt', @isstruct )
addRequired( IP, 'sbxInfo', @isstruct )
addRequired( IP, 'Tscan', @iscell )
addRequired( IP, 'loco', @isstruct )
addRequired( IP... |
fb172aee94033a530ef8de340eead15bc4f66ca7571363a1eab5cf7dd17176da | MATLAB | 13,884 | 316 | %==========================================================================
% This script examines the memory performance of the subjects.
%
% Lukas Kunz, 2023
%==========================================================================
% start
clear; close all; clc;
addpath(genpath('E:\OpenField\Functions\'));
% path... |
a0d977315cd9ff7815f59fb35ae088bd1d809863f82678c5e8dcfb81ba80bada | MATLAB | 13,897 | 391 | classdef DataDetectSigsClsfy < DataDetectSigs
%DataDetectSigsClsfy - Data from signal detection and classification
%
% The DataDetectSigsClsfy class is a data class that is designed to
% contain all the data output from CalcDetectSigsClsfy.
%
% DataDetectSigsClsfy public properties inherited from Data:
% mask ... |
1dc368a2247c323ed65b0ac9c4aabbe59d85120ebb8ef671e93dc753987ae504 | MATLAB | 13,981 | 355 | function val_voxel_covariate
% Calibration and cost of the voxel-/vertex-wise covariate path.
%
% A covariate given as one image per subject makes the design matrix vary across
% the brain: at every element the covariate columns are replaced by the local
% values and the model is refitted. Where the contrast is defined... |
b89dccbeb09297bda74b088018a4addae916cb598628a0afd71e6885ea2b8a3f | MATLAB | 14,008 | 364 | % STATS_TREE Collects tree statistics using TREES toolbox functions.
% (trees package)
%
% [stats name path] = stats_tree (intrees, s, name, options)
% ----------------------------------------------------------
%
% collects typical statistics on trees. A graphical output is controlled by
% dstats_tree. Input trees ca... |
2a132d40cb22cca8d51d47e4739d2d8d3c05a0e03bca323ce29ca4dbeb5351ee | MATLAB | 14,010 | 296 |
function [CSDoutput] = CSD(data,SR,spacing,varargin)
% Detemines the 1-dimensional (in space) current source density (CSD)
% for a set of voltage traces obtained from a linear array of
% electrodes of equal spacing. The CSD can be obtained using the
% standard CSD method (Nicholson & Freeman... |
4128821c31126e626fe6e11d42b6ce142d2e25fdc1dbe373a6bc1dd5ae459eb3 | MATLAB | 14,064 | 371 | % run_simPressShaped_fast.m
% Dana Goerzen and Jamie Near, McGill University 2021.
%
% USAGE:
% out=run_simPressShaped_fast(spinSys);
%
% DESCRIPTION:
% This script simulates a PRESS experiment with fully shaped refocusing
% pulses. Coherence order filtering is employed to only simulate desired signals
% This result... |
ec49e8e30cc3a695ffa29585ae0fc7afa721de6d56e73b2f09425d6c2ef5aef7 | MATLAB | 14,082 | 369 | classdef CompositeImg < ImgGroup & IRawImg
%CompositeImg - Class to contain groups of images from the same raw image
%
% The CompositeImg class implements most functionality related to groups
% of ProcessedImg objects that are derived from the same RawImg object.
% This allows efficient use of memory, since the s... |
461b4636c7dd3565b1f9ab3dcd79864ee4dc35e74dec7b07ed47746fc4eb1d7b | MATLAB | 14,087 | 321 | function varargout = sendSamples(obj, varargin)
% Send waveforms for stimulation to the DAQ. Stimulation starts immediately or following a trigger.
%
% [conditionNum, laserOn, waveforms] = zapit.pointer.sendSamples(newTrial, verbose)
%
%
% Purpose
% This method is a critical part of the API ... |
67a88082729ba1f3de12e2c1c6780a397d0a885d6487b4692627028344080686 | MATLAB | 14,093 | 346 | %@file OptimizeNeurostim_FixedLengthscales.m
%@authors Marco Bonizzato https://github.com/mbonizzato
% Olivier Caron-Grenier https://github.com/OlivierCG
%@version 1.0 / June 2021
%Fixed-lengthscales (rho) implementation of GP-BO optimization of neurostimulation
%The code below displays algorithmic p... |
3f09d776ddb16fb2cdad615f4498dfc2b76e8814e39c832364a7ca38d14042b4 | MATLAB | 14,133 | 319 | function [nodes,layersAP,plane,tree] = CA1pyramidalcell_divide(tree,addsoma,plot)
% Function to divide CA1 cells into differen regions and layers
% [nodes,layersAP,perp_dist,tree]
% INPUT:
% Tree tree structure
% Options '-s' plot all the different partitions
% OUTPUT: all logical arrays that... |
5ed2a5695e551372e362d32cff8f536465a5b48936f931b1dd62ff998616407c | MATLAB | 14,158 | 484 | function [varargout] = ft_notification(varargin)
% FT_NOTIFICATION works mostly like the WARNING and ERROR commands in MATLAB and
% is called by FT_ERROR, FT_WARNING, FT_NOTICE, FT_INFO and FT_DEBUG. Please note
% that you should not call this function directly.
%
% Some examples:
% ft_info on
% ft_info on msgId
% ... |
406dad60ffd77287819b596bb3782ad7c19349166d4eaec0224e0f904814e2a1 | MATLAB | 14,181 | 374 | function [output,extras] = urlread2(urlChar,method,body,headersIn,varargin)
%urlread2 Makes HTTP requests and processes response
%
% [output,extras] = urlread2(urlChar, *method, *body, *headersIn, varargin)
%
% * indicates optional inputs that must be entered in place
%
% UNDOCUMENTED MATLAB VERSION
%
%... |
99b3eec768d64238efed0ce28a3d10b3fbad30ad493f25e36636cadbbb4adb0c | MATLAB | 14,183 | 318 | function ViewResults3D(expt, T, deform, loco, fluor, viewVars, varargin)%ROI, projRGB =
%
IP = inputParser;
addRequired( IP, 'expt', @isstruct )
addRequired( IP, 'T', @iscell )
addRequired( IP, 'deform', @isstruct )
addRequired( IP, 'loco', @isstruct )
addRequired( IP, 'fluor', @isstruct )
addRequired( IP, '... |
b5c83ce3974f0577885dadde82665070398a06a63e06da86f13d3f64baa1587a | MATLAB | 14,201 | 335 | % UNDERSTANDING METRICS
%
% The purpose of this tutorial is to gain a better understanding of
% the different classification and regression metrics in MVPA-Light as well
% as the different types of outputs that classifiers produce.
%
% Contents:
% (1) Classification: Relationship between dvals (decision values), accura... |
dbb5da1dd5cb7dc32b3b07ae19e2eea236b9dd5ed8cb756fb3cc2e5bd94da0ec | MATLAB | 14,259 | 380 | %% Create barcodes plot and data
data=DataSet;
'tic'
tic
cluster_size=450; %minimal number of data points per cluster
distances = squareform(pdist(data));
distances(distances == 0) = 1; %
r_vec = 0.000015:0.00001:0.003;
all_bins_mat=nan(length(distances),length(r_vec));
values_array={};
indices_array={};
occurrences... |
0166376df64ae1c178a86a7db3b5b3c0de9cd9ae9bbf694c9dc7495dcc9b7bd3 | MATLAB | 14,273 | 256 | %% Use GLM to assess contribution of different variables
runGLM_pred = cell(1,Nexpt); runGLM_resp = cell(1,Nexpt); runGLM_opts = cell(1,Nexpt); runGLM_result = cell(1,Nexpt); runGLM_summary = cell(1,Nexpt);
figDir = 'D:\MATLAB\LevyLab\Figures\3D\GLM\'; mkdir( figDir )
GLMname = 'runGLM_TScShDtStDshZVAL_80pct';
GLMr... |
822698f9390c5ad15238c100fa8af21c5c1e6dc22ba832d91a661a15375051e3 | MATLAB | 14,332 | 387 | %%Aberra model for TMS L5 PC
% MATLAB adaptation, Nicholas Hananeia 2021
function[] = Aberra_L5_model()
fclose('all');
% install T2N and TREES and add path for necessary files
run('./lib/init_t2n_trees.m');
if ~exist('./Aberra_files/lib_mech/nrnmech.dll', 'file') && ~exist('./Aberra_files/lib_mech/x86_64/.l... |
a1df4292ca6e5b3dc2308c968429087503d6c62b6c5e6730b5e3e3394b3db20d | MATLAB | 14,370 | 209 | % Aggregates grand average waveform (GAW) results over all nodes and
% subjects
%
% USAGE:
% GAW = computeGAWs_fast_timescale_agg(GAWnode_filenames)
%
% INPUTS:
% GAWnode_filenames - cell array that contains filenames for results from
% computeGAWs_fast_timescale.m.
%
% OUTPUTS:
% GAW ... |
e4629a98089ea588754cd6d786bfb0fb7044b317e27ca56641221eaea2e72efc | MATLAB | 14,390 | 433 | % FigureS17.m
% Plots for Supplementary Figure S17.
%
% EEG/fMRI STUDY, DONDERS INSTITUTE, NIJMEGEN.
% J. Algermissen, 2018-2023.
% Should work in Matlab 2018b.
% we are here:
% cd /project/3017042.02/Analyses/FiguresOutcomeLocked
% clear all; close all; clc
% Set root directory:
cd(fileparts(which('figures_set_roo... |
91263a580ca020dd1f94f48f93fc41947dd4a2550f7ec6bbd9330987260e42df | MATLAB | 14,421 | 180 | %% Load data and compose metrix
clear all; close all; clc;
load('DSE1-738_20210915 DBS stim with C1V1.mat');DSE1_465Sig = data.Normalized465; clear data;
load('DSE2-739_20210915 DBS stim with C1V1.mat');DSE2_465Sig = data.Normalized465; clear data;
load('DSE3-745_20210910 DBS stim with C1V1.mat');DSE3_465Sig = da... |
5b73b7a172ac5221a3b9db7ddd6135fad8ab22f442e2bd261577cfc48334ad7c | MATLAB | 14,461 | 388 | % Assess whether we can account for FI differences between V1 and MT based
% on substituting a single parameter distribution from one to the other
clear all; close all;
% Set the random seed to a specific value so that bootstrapping results are reproducible
rng(724);
% number of times to resample parameters
numResam... |
d914dc35d021755cf50cd9d2f89ead7db3e8eede001e97b55fc8ee1e55a50383 | MATLAB | 14,469 | 365 | % DSTATS_TREE Display tree statistics obtained by stats_tree.
% (trees package)
%
% HP = dstats_tree (stats, vcolor, options)
% -----------------------------------------
%
% Displays some statistics of trees. "stats" can be a structure obtained
% from stats_tree or can be read out from an ".sts" file.
%
% Inputs
% --... |
d013f2ef58cca781d8623d53fa6e5e9a6625de981c5873ae05cb217aa0658d5e | MATLAB | 14,498 | 367 | function [job] = TF_update_job(job)
% [job] = TF_update_job(job)
%
% Complete settings for job on TF-domain data to create.
% (data sets to create; plotting settings).
%
% INPUTS:
% job = cell, created via TF_update_job.m, needs at least
% fields:
% .nSub = integer, number of subject... |
dff2001146af4e0bc68b5bd8e85b9d924d07be2430f309341061b493d451a208 | MATLAB | 14,506 | 357 |
function [tbl, corrupt_ids] ...
= extract_FreeSurferLobes_features(subjdir, ids, oldtbl, varargin)
% This function extracts the numeric data from FreeSurfer subjects into
% one table on a lobe-basis, which is returned and can optionally be saved.
% The table format is chosen so that it can easily be ID-joined with a
%... |
8d66815ba4fd9365ea1d853962f719dfbd0fb024b52026f958a35d612b0febb8 | MATLAB | 14,597 | 319 | %% To load multiple basecalls:
LIBRARY_FILE = 'groundtruth_dictionary_splintr2';
ptr = 1;
loadParameters;
basecalling;
num_reads = size(insitu_transcripts,1);
insitu_transcripts_total(ptr:ptr+num_reads-1,:) = insitu_transcripts;
insitu_transcripts_2ndplace_total(ptr:ptr+num_reads-1,:) =... |
eecf8ddce6f0915505cc4bb2f6a36b25972be77d0f0b1558757927246927c0ea | MATLAB | 14,613 | 279 | function [fluor, ROI, expt] = GetTraceCat3D(expt, fluor, deform, T, varargin) % , run exptDir, exptName %ROIlabel,
IP = inputParser;
addRequired( IP, 'expt', @isstruct )
addRequired( IP, 'fluor', @isstruct )
addRequired( IP, 'deform', @isstruct )
addRequired( IP, 'T', @iscell )
addParameter( IP, 'corrPrct', 68, ... |
8069c85f975b992c54c5a547e00850e6ff9efe2dd4734038455617ba199b0d1b | MATLAB | 14,733 | 435 | % FigureS16.m
% Plots for Supplementary Figure S16.
%
% EEG/fMRI STUDY, DONDERS INSTITUTE, NIJMEGEN.
% J. Algermissen, 2018-2023.
% Should work in Matlab 2018b.
% we are here:
% cd /project/3017042.02/Analyses/FiguresOutcomeLocked
% clear all; close all; clc
% Set root directory:
cd(fileparts(which('figures_set_roo... |
9833ca2e10659c15f0e02c37f43eb3db9a8c32281e6cf712233a1c75e93e4863 | MATLAB | 14,776 | 431 | function data = TDTbin2mat_old(BLOCK_PATH)
%TDTBIN2MAT TDT tank data extraction.
% data = TDTbin2mat(BLOCK_PATH), where BLOCK_PATH is a string, retrieves
% all data from specified block directory in struct format. This reads
% the binary tank data and requires no Windows-based software.
%
% data.epocs ... |
d378e739b835057454f357c603abf2c1f48a443d36b809acc076adf9a7afefa7 | MATLAB | 14,779 | 405 | classdef Test_CompositeImg < matlab.unittest.TestCase
%TEST_COMPOSITEIMG Summary of this class goes here
% Detailed explanation goes here
% ================================================================== %
methods (Test)
function testConstructor(self)
... |
90fbaca2a167976c1dc5174b8bf770f4a7660ef3a5a50984209ecd24c156f213 | MATLAB | 14,804 | 367 | load(fullfile(dataFolder,'EEG_data','data_time_information.mat'));
t0 = timeInfo.infusion_onset-timeInfo.object_drop;
rescaled = load(fullfile(dataFolder,'EEG_data','electrode2_Cz_rescaled_time.mat'));
rescaled.psd = log10(rescaled.psd);
aligned = load(fullfile(dataFolder,'EEG_data','electrode2_Cz.mat'));
load(fullf... |
d1dfb8c64688a3bcc2f3f88b93b6c640b16c57910a1d1a0e7c4bed4c556d4a58 | MATLAB | 14,880 | 373 | %% In the main analysis, we computed Fisher information for each neuron,
% then summed them up because we assumed
% statistical independence. In this control analysis, we'll test how the
% results might change if the neurons has statistical dependences
clear all; close all;
% Load Gabor fitting results of the neuron... |
93e5cc740d7ce2c6db4f55ded1ce4144ff1d02d7d167d93542899255d24f6eca | MATLAB | 14,953 | 391 | classdef CalibrationPixelSize
%CalibrationPixelSize - Class containing a pixel size calibration
%
% The CalibrationPixelSize class is a data class that is designed to
% contain a calibration relating a given microscope zoom factor to a
% known physical pixel size (in units of distance).
%
% Please see the <a hr... |
e993285bed638e0e5dd3bfcf0d3bbd4b911841345efd442fac9709394822e1c1 | MATLAB | 14,999 | 396 | % run_specialproc_fmrs.m
% Jamie Near, McGill University 2014.
%
% USAGE:
% [out_stimOFF,out_stimON,out_w]=run_specialproc_fmrs(filestring,blockDesign,leadingAvgsToRmv);
%
% DESCRIPTION:
% Processing script for functional MRS data acquired using the SPECIAL MRS
% sequence. This script accepts data in Siemens .dat f... |
9000daf93b6cd2a2eae70c1726be2356b5992711dc7bcca6ff6b07eda0972408 | MATLAB | 15,015 | 367 | classdef sampHighOrder
% Perform MRI sampling using direct summation of complex exponentials.
% Supports B0 map, time-varying spherical harmonic distributions of phase,
% and time-varying distributions of phase that are typical for concomitant
% gradients. Currently 2D only.
%
% Usage:
% Define sampHighOrder object ... |
893cfaf5511b80252ad12e34c180f9a4b24e0d865a4cbabc6523ec6e40c21255 | MATLAB | 15,024 | 408 | % run_pressproc_GEauto.m
% Jamie Near, McGill University 2014.
%
% USAGE:
% [out,out_w,out_noproc,out_w_noproc]=run_pressproc_GEauto(filestring,aaDomain,tmaxin,iterin);
%
% DESCRIPTION:
% Fully automated processing script for GE PRESS MRS data in p-file
% format (GE raw data). Includes combination of reciever chann... |
0c89c5fbe7769b8b2a9a4930bd8a1451bfadbb9e209632d469dbc8c7e81eed24 | MATLAB | 15,057 | 396 | % run_simSteamShaped_fast.m
% Jamie Near, Sunnybrook Research Institute 2022.
%
% USAGE:
% out=run_simSteamShaped_fast(spinSys);
%
% DESCRIPTION:
% This script simulates a STEAM experiment with fully shaped RF
% pulses. Coherence order filtering is employed to eliminate unwanted
% coherences. Furthermore, simulatio... |
2420a165f5071da43547ee14f33e9be527b05d3478eb98e968fa269bb23cfbe5 | MATLAB | 15,087 | 292 | function [stillEpoch, stillBin, stillSumm] = BinStillEpochs(expt, T, loco, fluor, deform, csdBout, varargin)
% Parse inputs
IP = inputParser;
checkData = @(x)(isempty(x) || isstruct(x));
addRequired( IP, 'expt', @isstruct )
addRequired( IP, 'T', @iscell )
addRequired( IP, 'loco', @isstruct )
addRequired( IP, 'fl... |
92480f49b3f6560f1a242c8fb4d2b6bd0b5dc9e8e66dc9d84f7ab96eef50dd01 | MATLAB | 15,114 | 504 | %io_loadspec_bruk.m
%Jamie Near, Sunnybrook Research Institute, 2023
%Wendy Oakden, Sunnybrook Research Institute, 2020
%Chathura Kumaragamage, McGill University 2016.
%
% USAGE:
% [out,ref]=io_loadspec_bruk(inDir, rawData, );
%
% DESCRIPTION:
% Reads in Bruker MRS data (fid.raw, fid.ref).
%
% op_loadspec_bruk reads a... |
1dd8f2082e65a356b22903dcc6c0a6d005350192e257bd5642f4aad032aac38f | MATLAB | 15,169 | 394 | %% Jarsky CA1 PC model generator for TMS simulation
% Implements the Jarsky model of the CA1 PC:
% Jarsky T, Roxin A, Kath WL, Spruston N (2005) Conditional dendritic spike propagation following distal synaptic activation of hippocampal CA1 pyramidal neurons. Nat Neurosci 8:1667-76
%
% Input: SWC or MTR file conta... |
3b61354d2a3304e269306ee06883a62856e66a99c55282f266251776b6363555 | MATLAB | 15,232 | 345 | classdef stimConfig < handle
% Configuration file handling class
%
% zapit.stimConfig
%
% Purpose
% This class handles configuration files used to determine where the laser stim
% locations are. Methods in this class generate the waveforms used for stimulus
% presentation. This class lo... |
984decf6fa1664594b02ac4913c9a1f285e2ce5c8d5459520d6d66c260e591d5 | MATLAB | 15,264 | 475 | function uTest_GetFullPath(doSpeed) %#ok<INUSD>
% Automatic test: GetFullPath
% This is a routine for automatic testing. It is not needed for processing and
% can be deleted or moved to a folder, where it does not bother.
%
% uTest_GetFullPath(doSpeed)
% INPUT:
% doSpeed: Optional logical flag to trigger time consum... |
89b00d781723f314f74b143fb39ef5d992418aa915f20c1bdaa6868357551a2f | MATLAB | 15,280 | 541 | %% cell numbers without normalization
load('E:\learningAnalysis\summaryManyMice_includingOldEnvGoodMoreMice\cellNumbersEachFOV\cellNumbers.mat');
G=cellNumbers(2:end,:);%remove the first mouse because it was 40x
load('E:\learningAnalysis\summaryManyMice_includingOldEnvBadMoreMice\cellNumbersEachFOV\cellNumbers.mat')... |
3943fd1d8a0cee6adbd1f30c4c9618ff7006bd24f9ef3cf3f373c6c6702e2371 | MATLAB | 15,282 | 348 | function EEGfMRIPav_OutcomeLocked_8_time_create(rootDir, subVec, baselineSettings, baselineTimings, ...
responseSettings, outcomeSettings, ROI2use)
% EEGfMRIPav_OutcomeLocked_8_time_create(rootDir, subVec, baselineSettings, baselineTimings, ...
% responseSettings, outcomeSettings, ROI2use)
%
% Load EEG, rejec... |
0a5fb16868d8dda3c4f9221dda28c8a30b6e143a8f4055d5a3c895d47c598d10 | MATLAB | 15,310 | 412 | % run_pressproc_brukAuto.m
% Jamie Near, McGill University 2014.
%
% USAGE:
% [out,out_w,out_noproc,out_w_noproc]=run_pressproc_brukAuto(filestring,filestringw,aaDomain,tmaxin,iterin);
%
% DESCRIPTION:
% Fully automated processing script for Bruker PRESS MRS data in fid.raw
% format (raw data). Processing steps inc... |
f69acf76b7248afd5ddc087b34126b2f6ea72daaa0819345516a613028e1fcd8 | MATLAB | 15,310 | 484 | function varargout = cptcmap(varargin)
%CPTCMAP Apply a .cpt file as colormap to an axis
%
% cptcmap(name);
% cptcmap(name, ax);
% cptcmap(... param, val, ...);
% [cmap, lims, ticks, bfncol, ctable] = cptcmap(...)
%
% This function creates and applies a colormap defined in a color palette
% table (.cpt file). ... |
70dd3f783decf5d3e50f953a0c8c135c59c4fed05177a28e3dedb60471f498d9 | MATLAB | 15,386 | 455 | % run_specialproc.m
% Jamie Near, McGill University 2014.
%
% USAGE:
% [out,out_w,out_noproc,out_w_noproc]=run_specialproc(filestring,aaDomain,tmaxin,iterin);
%
% DESCRIPTION:
% Processing script for Siemens SPECIAL MRS data in .dat format (twix raw
% data). Includes combination of reciever channels, removal of bad... |
dce51405e1533074a70c9376bf46197cebe969e26c1b95478dd405c8398f220b | MATLAB | 15,407 | 555 | function st_run()
%% stPRF experimental
% ========================================================================
% each run %%%%%%%%%
% stimulus radius = 12
% trial Dur = 5, blank Dur =10
% Number of Direction 4, number of steps 9
% Stimulus [4 directions * 9 steps * 5 seconds/location ] = 180 sec
% Initial blank (1... |
167e0539eb4938923e73ad401b132c0a7fc94c34523d248eb74d619a0d45df56 | MATLAB | 15,417 | 339 | %==========================================================================
% This script performs behavioral and ripple analyses regarding the initial
% encoding period.
%
% It estimates the duration of the initial encoding for each subject and
% performs analyses with regard to ripple rates during the initial encodin... |
10836cba3e06cd04f0c9ea1b2b48a2a8a6e1bc2caf5568f3bcea6d04fa1fddaa | MATLAB | 15,427 | 335 | %% To load multiple basecalls:
LIBRARY_FILE = 'groundtruth_dictionary_slice_v6_unique_everything_highcomplex.mat';
ptr = 1;
for fov_index = 1:10 %1 2 3 4 7 8 9 10] %4 6 7 8
loadParameters;
params.deconvolutionImagesDir= sprintf('/mp/nas0/ExSeq/AutoSeq2/xy%.2i/1_deconvolution',fov_index);
params.color... |
682f2b72aac461bf167f05eb53b6faf78a3f935341381bb9143f3222997a91c7 | MATLAB | 15,471 | 480 | ID='Gi17547'
inputname=strcat('SortedData_', ID, '.mat');
load(inputname)
disp('===LGL MSD excitatory response during swing===');
temp0=[];
temp1=[];
temp3=[];
temp7=[];
for i=1:length(SWING_LEFT.EXC(:,1))
if SWING_LEFT.EXC(i,1)==0 & SWING_LEFT.EXC(i,10)>0
temp0=cat(1,temp0, SWING_LEFT.EXC(i... |
f429318fd41b41876999f3f8a56596e430a18f92227341326c79d6f8f8acbbf9 | MATLAB | 15,511 | 423 | classdef controller < zapit.gui.main.view
% Controller class for main Zapit GUI
%
% zapit.gui.main.controller
%
% Purpose
% The "main" Zapit GUI is that which appears when the user runs "start_zapit".
% This class runs this GUI by controlling the elements defined by zapit.gui.main.view,
... |
e5729e76e70a540707114d9dda0a373fe2aca59cfa8ba5298e2809a74638ca72 | MATLAB | 15,518 | 378 | function ElectodesClassificationMatlabFuncV2LFP(unifyContextClasses ,averageAllBoutsFromSession ,...
NumTrees,TakeJustTheta,TakeJustGamma,matlabImpute,imputeIters, ...
substractMouseMean, usedMouseId,LeaveOut,balanceClasses,...
excludeClassesFromTrain,excludeClassesFromAnalysis, useStdMatrix, outFname)
... |
5ef0e92ffb80c29191ec561a9afd4e71f0b1a0691ad6ee78ad293ff420d5e3fc | MATLAB | 15,526 | 577 | p=pwd;
cd ..\
load('foldersAll.mat');
cd(p);
cueRRBR={};%each cell is a day
cueLRBR={};
for n=1:11;
cueRRBR{n}={};
cueLRBR{n}={};
end
for n=1:length(foldersAll);
disp(n)
cd(foldersAll{n});
load('reIdentifyCueCellsUniThreshAddingNewMice\indices.mat');
load('reIdentifyCueCell... |
16dedbd624dd3da0a213ec9330af27ce675b516dd7e3ab36f9ee50b9433c6b5e | MATLAB | 15,645 | 294 | function SpecificModSniffing_25032020(AllDataFiles,AllParameters,app)
%TRACKMICEPOPULATIONSUMMARY Summary of this function goes here
% The aim of this function is to summarize the results of several rodents extracted by the software TrackRodent.
NumOfFiles=[ length(AllDataFiles.TimeStampsfileList) ...
... |
b19f66d4fbb66acd821dadd60ea77ce5feb50a5cf1db1e4034ccc9c57c21a1e4 | MATLAB | 15,666 | 382 | function ElectodesClassificationMatlabFuncV2(unifyContextClasses ,averageAllBoutsFromSession ,...
NumTrees,TakeJustTheta,TakeJustGamma,matlabImpute,imputeIters, ...
substractMouseMean, usedMouseId,LeaveOut,balanceClasses,...
excludeClassesFromTrain,excludeClassesFromAnalysis, useStdMatrix, outFname)
%... |
cb243e6475b687e3d069abd9ab22665290b4b6dd222bfdfa63a07bd598b9b20f | MATLAB | 15,681 | 418 | function CellsortICAplot(mode, ica_filters, ica_sig, f0, tlims,...
dt, ratebin, plottype, ICuse, spt, spc)
% CellsortICAplot(mode, ica_filters, ica_sig, f0, tlims, dt, ratebin,
% plottype, ICuse, spt, spc)
%
% Display the results of ICA analysis in the form of paired spatial filters
% and signal ti... |
9a6d25d7718651ca6478200c83bd5d6c396cd36d870f3b9372a8ec07eae9dc4a | MATLAB | 15,687 | 384 | function ElectodesClassificationMatlabFuncV2LFP(unifyContextClasses ,averageAllBoutsFromSession ,...
NumTrees,TakeJustTheta,TakeJustGamma,matlabImpute,imputeIters, ...
substractMouseMean, usedMouseId,LeaveOut,balanceClasses,...
excludeClassesFromTrain,excludeClassesFromAnalysis, useStdMatrix, outFname)
... |
a686b9b26eb3a13ac1ccc2b5ede0956cc599a837f512d1e6cd273c5488d5fa75 | MATLAB | 15,703 | 362 | function EEGfMRIPav_OutcomeLocked_8_TF_create(rootDir, subVec, baselineSettings, baselineTimings, ...
responseSettings, outcomeSettings, ...
TFtype, nFreq, outERPcor, outERPresponseSettings, outERPoutcomeSettings)
% EEGfMRIPav_OutcomeLocked_8_TF_create(rootDir, subVec, baselineSettings, baselineTimings, ...
% ... |
0c6893d7fb875588bed6d73c205bad8e4c99f4e16a615fb4a9b3bc6b8d321ead | MATLAB | 15,718 | 412 | % UNDERSTANDING PREPROCESSING
%
% In this example we look into preprocessing pipelines. Preprocessing
% includes demeaning, z-scoring, PCA, sample averaging, feature
% extraction methods such as PCA, and any other
% approaches that operate on the data prior to training.
%
% An important distinction is between what wi... |
6a0c6cd33014e3bc8b488c3fcda231104256e16c8c311456f31d53ad4f5578c3 | MATLAB | 15,727 | 394 | % Figure05.m
% Plots for Figure 5A-G in manuscript.
%
% EEG/fMRI STUDY, DONDERS INSTITUTE, NIJMEGEN.
% J. Algermissen, 2018-2023.
% Should work in Matlab 2018b.
% we are here:
% cd /project/3017042.02/Analyses/FiguresOutcomeLocked
% clear all; close all; clc
% Set root directory:
cd(fileparts(which('figures_set_roo... |
61732cd669ad5c2ef54ac990b4a4672f69c870f14df06fa188546ed3c10e8c25 | MATLAB | 15,743 | 361 | %==========================================================================
% This script distinguishes between putatively excitatory and inhibitory
% cells and investigates their overlap with object/place cells.
%
% References:
% - Viskontas et al., Hippocampus, 2007
% - Ison et al., Journal of Neurophysiology, 2011
%... |
a634ced5744e3effcf408d6f2989f98fa759fbcca58efd4496602bca4ff243b3 | MATLAB | 15,744 | 296 | % 'analyse_pattern_separation' Master function to analyse pattern separation
% between input and output spiking ensembles using all classical and
% information-theoretic measures.
%
% (pattern separation toolbox)
%
%[patsep] = analyse_pattern_separation(input,output,options)
% ----------------------------------... |
555fa8f0a869edcaabaae1a3241b2e6dbbba32c634f443db4852ce0ff70a3aa8 | MATLAB | 15,780 | 355 | function [out] = taft_preprocess_load_behavior(job)
% [out] = taft_preprocess_load_behavior(iSub)
%
% Load behavioral data,
% recode response and accuracy variables (uninstructed keys to
% instructed keys; delete Gos with too long RTs, accuracy based on recoded
% keys presses),
%
% INPUTS:
% job = stru... |
be156f8e48e1ae5bb028592e284af3093f21dd37fe0d9ce724036bdf97658674 | MATLAB | 15,796 | 465 | function [resp, ok] = generalDialog(dlg, title, figPos)
%
% [resp, ok] = generalDialog(dlg, [title], [figPos])
%
% Create a dialog w/ UI control text, edit, popup,
% checkbox, or listbox menus for different items,
% and return a struct with the user-selected values
% in the appropriate fields. A replacement for general... |
2321711d58ef58d2b2a38e6c83b388e99fd5b2ba38e6375684cc08f99f5bb769 | MATLAB | 15,856 | 270 | function [cm_data]=magma(m)
cm = [[ 1.46159096e-03, 4.66127766e-04, 1.38655200e-02],
[ 2.25764007e-03, 1.29495431e-03, 1.83311461e-02],
[ 3.27943222e-03, 2.30452991e-03, 2.37083291e-02],
[ 4.51230222e-03, 3.49037666e-03, 2.99647059e-02],
[ 5.94976987e-03, 4.84285000e-03, ... |
dd5d8fc27bf9e133cb917ca0a9e3a584393092ed99dcc26f58c561d54fd3a6d8 | MATLAB | 15,875 | 423 | % run_pressproc_auto.m
% Jamie Near, McGill University 2014.
%
% USAGE:
% [out,out_w,out_noproc,out_w_noproc]=run_pressproc_auto(filestring,aaDomain,tmaxin,iterin);
%
% DESCRIPTION:
% Fully automated processing script for Siemens PRESS MRS data in .dat
% format (twix raw data). Includes combination of reciever chan... |
0382f767ad38f3b657871fb4a39159a8a20d6b63b6e4bb3ae7c6666d6a82db36 | MATLAB | 15,888 | 437 | classdef (Abstract) RawImg < RawImgHelper
%RawImg - Superclass for all 'normal' raw image classes
%
% The RawImg class is an abstract superclass that implements (or requires
% implementation in its subclasses via abstract methods or properties)
% most functionality related to 'normal' RawImg objects. 'Normal' Raw... |
7a9ea916cdd28d2e64139a326f18592dd8e204bb5e2958b7c691bb68f2d30924 | MATLAB | 15,888 | 414 | classdef Test_CellScan < matlab.unittest.TestCase
%Test_CellScan Summary of this class goes here
% Detailed explanation goes here
% ================================================================== %
methods (Test)
function testConstructor(self)
% Varia... |
34fd498c073fa72cebb853df31f966ecfc235c5000ba682b793427bdc149a254 | MATLAB | 15,906 | 71 | function cmap = turbo(n)
% cmap = turbo(n)
%
% n is the number of levels (spline-interpolated)
%
% Original python code by Anton Mikhailov
% [https://gist.github.com/mikhailov-work/ee72ba4191942acecc03fe6da94fc73f]
%
% (cc) 2019, sgKIM. solleo@gmail.com
% https://gist.github.com/solleo/f344283b8d11532b406a664723182f8b
... |
84da788deed419e3430ff36094c156ff4dea863d45363b36b68b7148ca963208 | MATLAB | 15,939 | 495 | %% Summarize results of fitting cell populations with Gabors, subsample
% cells using criteria that we want and perform some additional
% calculations used at later stages
clear all; close all;
% Flag = 1 if you want to plot the fit for each cell
plotallfits = 0;
% load symbolic equations for Gabor and first derivat... |
7636bb4d10dcf57e49b80c16013940caae24dc91d52208cfe79d71427446107e | MATLAB | 15,953 | 298 | function SpecificMod_FiberPhotometry_29032020(AllDataFiles,AllParameters,app)
%TRACKMICEPOPULATIONSUMMARY Summary of this function goes here
% The aim of this function is to summarize the results of several rodents extracted by the software TrackRodent.
NumOfFiles=[ length(AllDataFiles.TimeStampsfileList) ...
... |
2967fe42a8dfc4deffc85a610bcbdac17bc45032532c844c1cfdfabde251fd2a | MATLAB | 15,966 | 503 | function [data, timestamps, info] = load_open_ephys_data_chunked(filename,t1, t2)
%
% [data, timestamps, info] = load_open_ephys_data_chunked(filename,t1,t2)
%
% Loads continuous, event, or spike data files into Matlab.
%
% Inputs:
%
% filename: path to file
% t1: start time in seconds
% t2: end time in... |
eb193ee3a84bbd1922443d97c891b3745c0a1e579af76af11f7e14c4c3bff545 | MATLAB | 15,994 | 394 | function out = taft_save_PEs(iSub, saveToDisk)
% taft_save_PEs(iSub)
%
% Load behavioral data, compute standard and biased PEs, save as .csv
% files.
%
% INPUTS:
% iSub = scalar integer, ID of subject to load.
% saveToDisk = Boolean, save to disk under dirs.target (optional;
% default: true).
%
% ... |
58ac83efda71ccca366d7efb7447a66a24fbf870c844746ac44489480596bb08 | MATLAB | 15,997 | 416 | classdef (Abstract) StreakScan < ProcessedImg & ICalcVelocityStreaks
%StreakScan - Superclass for streak scan processable images
%
% The StreakScan class is an abstract superclass that implements (or
% requires implementation in its subclasses via abstract methods or
% properties) most functionality related to im... |
a3270c81f81bcc8c53e1cb2c69d4d4fdf31eee123c0fc4ba887db09f2fe8d890 | MATLAB | 16,000 | 410 | % 2021 EDIT: This function is now deprecated. The current version of the shaped PRESS
% simulation is run_simPressShaped.m. The current version employs coherence selection,
% resulting in a 4x simulation speed increase.
%
% run_simPressShaped_fast_phCyc.m
% Jamie Near, McGill University 2018.
%
% USAGE:
% out=run_si... |
7261e15f238097ba631f683c066b4b5647f3e10649452d7f9be146e639ab959d | MATLAB | 16,057 | 454 | % Parental touch trial (Petal)
% Script 2 to perform the main analysis of primary and secondary outcomes
% and to generate related figures.
% October 2023
% ISRCTN Number: 14135962
% Clinicaltrials.gov identifier: NCT04901611
%% set path, select analysis type, select outcome list
clear;
% paths
path_to_inputFolde... |
6fcc33fa9bd66de0dede5343fcb41466ca8516bd09d5e69b9e056075fc0ef619 | MATLAB | 16,090 | 523 | function varargout=notBoxPlot(y,x,varargin)
% notBoxPlot - Doesn't plot box plots!
%
% function notBoxPlot(y,x,'Param1',val1,'Param2',val2,...)
%
%
% Purpose
% An alternative to a box plot, where the focus is on showing raw
% data. Plots columns of y as different groups located at points
% along the x axis defined by t... |
d6676f69b4933e499345e9e3fd848cabf48071ce8e716e1a13691ef8006f4284 | MATLAB | 16,123 | 433 | % FigureS21DEF.m
% Plots for Supplementary Figure S21, panels D, E, and F.
%
% EEG/fMRI STUDY, DONDERS INSTITUTE, NIJMEGEN.
% J. Algermissen, 2018-2023.
% Should work in Matlab 2018b.
% we are here:
% cd /project/3017042.02/Analyses/FiguresOutcomeLocked
% clear all; close all; clc
% Set root directory:
cd(fileparts... |
c03c8a157a6a3d1973cc53f84ffb9755d18e4285a58f910c7dc822b85884d325 | MATLAB | 16,206 | 408 | classdef pointer < handle
% Main API class for the Zapit optostim system
%
% zapit.pointer
%
% Purpose
% Drives a galvo-based photo-stimulator. The scan-lens doubles as an objective to
% scan the beam over the sample and also to form an image via a camera.
%
%
% Maja Skretowska -... |
f69fbc528f7d9a7ca382ad9e304c966eb2f211af7936ad2fb8f41b63a5487eef | MATLAB | 16,243 | 399 | classdef ConfigVelocityRadon < Config
%ConfigVelocityRadon - Parameters for Radon-based velocity calculation
%
% The ConfigVelocityRadon class is a configuration class that contains
% the parameters necessary for calculating velocity based on the Radon
% transform algorithm. For more information on the algorithm... |
9299b71aee0f837e18ebf40ca6a4cd22b3207e5b71dfc3eee7c78071e589828f | MATLAB | 16,302 | 399 | % GSCALE_TREE Scales trees from a set of trees to mean tree size.
% (trees package)
%
% [spanning ctrees] = gscale_tree (intrees, options)
% --------------------------------------------------
%
% Extracts region by region features from a group of trees intrees which
% are sufficient to constrain the artificial genera... |
f074f8395db3ffcdbc83ec3add1b32216aea7b5198bb7674538210e9f5c0f5a1 | MATLAB | 16,308 | 388 | classdef Test_StreakScan < matlab.unittest.TestCase
% TEST_STREAKSCAN Summary of this class goes here
% Detailed explanation goes here
% ================================================================== %
properties (Constant)
colsVelIn = [1 128];
end
% ====================... |
000fdcc099c031293a176e261238a50de73f6cb51818d0638a19853cab341ac5 | MATLAB | 16,377 | 441 | close all
clear
clc
%% Parameters
% ------------
T = 2; % duration, seconds
dt = 1e-3; % 1ms
fs = 1/dt; % 1kHz
bin_size = 1e-3; % 1ms
areas = {'EC', 'DG', 'CA3', 'CA1'};
types = {'pyCAN', 'py', 'inh'};
dirs = {};
dirs.results = '../../results/';
dirs.data = strcat(dirs.results, 'analysis/data/');
dirs.spikes = str... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.