sha256 stringlengths 64 64 | language stringclasses 28
values | size int32 1 491k | lines int32 1 23.2k | content stringlengths 1 200k |
|---|---|---|---|---|
0ec5d45de8ac15eee7f0734ccc7618c422bb286d542b4fe4599c8c5f29b9fd66 | MATLAB | 32,603 | 753 | % POP_SELECT - given an input EEG dataset structure, output a new EEG data structure
% retaining and/or excluding specified time/latency, data point, channel,
% and/or epoch range(s).
% Usage:
% >> OUTEEG = pop_select(INEEG, 'key1', value1, 'key2', value2 ...);
%
% Graphic interface:
%... |
fd43d51ed847c8f98ffa0c997b34212bd63804824010eb0b2753b31545dbd62a | MATLAB | 32,615 | 735 | % STD_LIMO - Export and run in LIMO the EEGLAB STUDY design.
% call limo_batch to create all 1st level LIMO_EEG analysis
%
% Usage:
% [STUDY LIMO_files] = std_limo(STUDY,ALLEEG,'key',val)
%
% Inputs:
% STUDY - studyset structure containing some or all files in ALLEEG
% ALLEEG - vector of loa... |
6727b87b66f5c310e8cf6c5fcdea6c7893dba83c6cf63e51b72c7a23c10dce7c | MATLAB | 32,619 | 376 | function plot_neural_selectivity_fraction
close all
clear all
clc
% Plot fractions of neurons showing task variable selectivity.
% Select a folder containing data.
folder_name = uigetdir;
cd(folder_name)
% Control.
load('activity_control.mat')
activity = activity_control;
clear activity_control
% Initialize.
for re... |
a64c5cff60b3d5100fc4c62b955618ffc14cc58de9f91d99e1f939d88ee02ee8 | MATLAB | 32,657 | 708 | % TIMEFREQ - compute time/frequency decomposition of data trials. This
% function is a compute-only function called by
% the more complete time/frequency functions NEWTIMEF
% and NEWCROSSF which also plot TIMEFREQ results.
%
% Usage:
% >> [tf, freqs, times] = timefre... |
71ef9d6dadb2051384f6f390a0f82f9da862b82d3cba4b9dc6371842b27e647c | MATLAB | 32,704 | 758 | % POP_SELECT - given an input EEG dataset structure, output a new EEG data structure
% retaining and/or excluding specified time/latency, data point, channel,
% and/or epoch range(s).
% Usage:
% >> OUTEEG = pop_select(INEEG, 'key1', value1, 'key2', value2 ...);
%
% Graphic interface:
%... |
c9a40633006c1d717961fcb0eacf59ffe7b5e865749702596915b6a7223fbfb4 | MATLAB | 33,109 | 636 | % STD_PLOTCURVE - plot ERP or spectral traces for a STUDY component
% or channel cluster
% Usage:
% >> std_plotcurve( axvals, data, 'key', 'val', ...)
% Inputs:
% axvals - [vector or cell array] axis values for the data.
% data - [cell array] mean data for each subject group and/or dat... |
364ffcd3008300f17d0a2b2abcb5207ed04d8f789164c245d800f206656ab44e | MATLAB | 33,275 | 710 | %% Calculating ICC Values for Functional Connectivity and Brain Variability in Affected
%% vs. Unaffected Brain ROIs by Creating a Map of Electrode Spatial Trajectory,
%% and Analysis of Affected vs. Unaffected ICCs (Figure 5)
% This script identifies which ROIs are affected and unaffected by the DBS
% leads, calcul... |
3ee851f57a7cd261f6711a9df8af059ec3ee070e13ea97d0e597f1154c4839a0 | MATLAB | 33,311 | 701 | clear;
cd(fileparts(matlab.desktop.editor.getActiveFilename));
%% ------- User controls (safe to edit) -------
bids_root_dir = 'F:/BIDS/WCH_AF_Project';
cvdproc_dir = 'E:/Codes/cvdproc';
FS_HOME = '/usr/local/freesurfer/7-dev';
ants_path = ""; % currently not used
% How to pick subjects/sessions:... |
e3ceff7c5077a920c17e3365f5b38a9e12b6bfa21039db091aed53a072d602fa | MATLAB | 33,440 | 959 | function [ subject, data ] = nmri_make_hdm_suma(subject, data, params)
%[ subject, data ] = nmri_make_hdm_suma(subject, data, params)
%
% This function will deal with reading the MRI info
% per default will read from SUMA, other options we be integrated later
% will assume that the subject.id = basename
% otherwise... |
95eb72170719557d065477e4fafa239eb9269d1354b3342fc13cd116216406d4 | MATLAB | 33,526 | 693 | % POP_RUNICA - Run an ICA decomposition of an EEG dataset using RUNICA,
% BINICA, or another ICA or other linear decomposition.
% Usage:
% >> OUT_EEG = pop_runica( EEG ); % pops-up a data entry window
% >> OUT_EEG = pop_runica( EEG, 'key', 'val' ); % no pop_up
%
% Graphic interface:
% "ICA algori... |
1585bc520872988369032f704c27b504e4faba9bb03ce8737be9e77bcecf79fa | MATLAB | 33,650 | 543 | function Lure_vs_Dissimilarity(GenPlots,IT_Fam_VE,HC_Fam_VE,IT_Fam_FR,HC_Fam_FR,IT_Fam_FV,HC_Fam_FV,IT_Lure_VE,HC_Lure_VE,IT_Lure_FR,HC_Lure_FR,IT_Lure_FV,HC_Lure_FV,zScore_flg,plot_RS_vs_Dissim,plot_GMFR)
%Lure_vs_Dissimilarity
%{
This function runs a cross validated classifier (both SCC and FLD) for
classifier perfor... |
522c9f07904ef64c11e6b462099f450b71afc0b4f7bb91b9e44b390bfbd046e1 | MATLAB | 33,665 | 919 | function [mri] = ft_read_mri(filename, varargin)
% FT_READ_MRI reads anatomical and functional MRI data from different file formats.
% The output data is structured in such a way that it is compatible with
% FT_DATATYPE_VOLUME.
%
% Use as
% [mri] = ft_read_mri(filename, ...)
%
% Additional options should be specifie... |
7138d21fa0cc9a9eb13815ee97d3b90d0806258b874adb4545ad65503f71c3bd | MATLAB | 33,700 | 1,025 | % EEGPLOTOLD - display data in a horizontal scrolling fashion
% with (optional) gui controls (version 2.3)
% Usage:
% >> eegplotold(data,srate,spacing,eloc_file,windowlength,title)
% >> eegplotold('noui',data,srate,spacing,eloc_file,startpoint,color)
%
% Inputs:
% data - Input data matrix... |
448920632ebf0b193d4f9ee3423870c1efdd264075bb2575833cd5ad65427349 | MATLAB | 33,730 | 717 | function out = SP_Summaries(y, psdMeth, windowType, nf, doLogAbs)
% SP_Summaries Statistics of the power spectrum of a time series
%
% The estimation can be done using a periodogram, using the periodogram code in
% Matlab's Signal Processing Toolbox, or a fast fourier transform, implemented
% using Matlab's fft code.
... |
1c036158a112b80c5e95b57de6d822aa4a62f7f3fa566c6fb66aef4c5c17d161 | MATLAB | 33,832 | 748 | % GEDAI() - This is the main function used to denoise EEG data using
% generalized eigenvalue decomposition coupled with an EEG leadfield matrix
%
% GEDAI (Generalized Eigenvalue Deartifacting Instrument)
%
% Usage:
% Example 1: Using all default values (and no bad epoch rejection)
% >> [EEG] = GEDAI(EEG);
%
... |
839c375b884527cdc1f90f62e1952f0909dd634971e7ef6c0b76d8d0d1d57072 | MATLAB | 33,906 | 848 | % TOPOREPLOT - re-plot a saved TOPOPLOT output image (a square matrix)
% in a 2-D circular scalp map view (as looking down at the top
% of the head). May also be used to re-plot a mean TOPOPLOT
% map for a number of subjects and/or components without all
% the co... |
46e22af5f993ef70249728c550cdd26a8607830557a52ff30565be897563f235 | MATLAB | 33,921 | 634 | function results = socialDecisionRespo_fMRI
% Code to run the fMRI experiment of the Responsibility Experiment. All
% instructions in German.
%
% J Schultz, M Gädeke and T Willems, University of Bonn 2017-2024
% Based on the PsychtoolBox 3's OldNewRecogExp.m (http://psychtoolbox.org)
%
% Builds on the experiment... |
038f1919121406fd9e1edc67e7d045b1e32b259fbb61bf822894903df3d08161 | MATLAB | 33,945 | 821 | function chantype = ft_chantype(input, desired)
% FT_CHANTYPE determines for each individual channel what chantype of data it
% represents, e.g. a planar gradiometer, axial gradiometer, magnetometer,
% trigger channel, etc. If you want to know what the acquisition system is
% (e.g. ctf151 or neuromag306), you should n... |
44b850545e131b58566835ef96ac0a25de4f94dc129b7f093333ada47cda5cfa | MATLAB | 34,064 | 67 | %% 400 EXAMPLES OF ASSEMBLY CONFIGURATIONS WITH 10 ASSEMBLIES IN A HONEYCOMB STRUCTURED TECTUM
% THERE ARE 40 CONFIGURATIONS WHICH ARE EMBEDDED IN TECTA OF INCREASING
% DEGREE v = 8 , ... 17
%
% THE ASSEMBLIES WERE CREATED IN HONEYCOMB STRUCTURED TECTUM OF DEGREE 8
% FROM n = 36 POINTS DRAWN FROM A 2D-NORMAL DISTRIBUTI... |
32fccbbe2302604b899374013bd85b40d5a06fcd6afcdf5f2f0dcde6ab0ad6ef | MATLAB | 34,186 | 807 | % A UIMULTICOLLIST must be created before it can be operated on
% The initial values are arg pairs as per a UICONTROL of style listbox.
%
% Calling with no arguments provides a dynamic list of the methods available:
% UIMULTICOLLIST
%
%
% h = UIMULTICOLLIST ( figHandle );
% h = UIMULTICOLLIST ... |
6bea6678c022bbadec8a35eada5f297a524fd05658da35a7fc16928ed9865939 | MATLAB | 34,245 | 748 | function [ifeat,testStat,testStat_rand,featureClassifier] = TS_TopFeatures(whatData,whatTestStat,cfnParams,varargin)
% TS_TopFeatures Top individual features for discriminating labeled time series
%
% This function compares each feature in an hctsa dataset individually for its
% ability to separate the labeled classes... |
7257e30861f1e99c8dc8568dbf86e33b4a4792f8b0c363a9f6c4fccb8d166002 | MATLAB | 34,417 | 803 | function [MRSCont] = OspreyQuantifyMRSI(MRSCont)
%% [MRSCont] = OspreyQuantifyMRSI(MRSCont)
% This function transforms the raw amplitude parameters determined during
% OspreyFit into MRSI amplitude maps.
%
% By default, OspreyQuantify will report tCr ratios for all metabolites.
% These values will not undergo a... |
193be75cef38e7d36c232ff4c939c297a5beb9475b68a889be5b0feda2f6be0d | MATLAB | 34,481 | 802 | function [fh, plotImage] = plot(this, varargin)
% plots an MR image
%
% Y = MrImage
% fh = Y.plot('ParameterName', ParameterValue)
%
% Note:
% The first (specified) dimension will be plotted from left to right
% The 2nd (specified) dimensions will be plotted from down to up
% The 3rd (and higher) specified d... |
3315e013697c252b110ffea77e039a66cd594f5469b40cf4b9497603c0f2bb70 | MATLAB | 34,490 | 602 | function plot_communication_subspace_similarity_epoch
close all
clear all
clc
% Plot communication subspace similarity in each epoch.
% Select a folder containing data.
folder_name = uigetdir;
cd(folder_name)
load('population_regression_control.mat')
load('population_regression_APP.mat')
% Stimulus.
% Control.
mean... |
ab97e0be16ccfe3cfb615e2293c0b2fe9cb5f8ccd2aab0a60937cb9261abc536 | MATLAB | 34,586 | 994 | function coactPaper_figureS18()
labelWeight=true;
labelCase=false;
labelSize=9;
letGapX=5;
letGapY=6;
fontsize=6;
close all
fh=initFig('width',18.6,'height',12.0,'font','Arial','fontsize',fontsize);
x=14;y=6;
panel_01(x,y,fontsize);
panelLetter2(x-letGapX-4,y-letGapY+1,alphabet(1,labelCase),'fontSize',labelSize,'isBo... |
a20ce707749eaa5ce432756627a58da0d9fb351f511aa50fc56fc9dcdf78a418 | MATLAB | 34,623 | 802 | function [x, cost, info, options] = trustregions_test_rho(problem, x, options)
%
% April 17, 2018: trying to work with rhonum and rhoden separately. It
% doesn't work because close to convergence rhonum cannot be trusted. The
% idea was to prevent the cost from going up even a little bit. Seems what
% we need is a go... |
5c4f94734d213ffaf03a2a87d06d61c5b2597814451b576697a0f0324c1e8639 | MATLAB | 34,867 | 684 | function find_best_spike_result(wavelet_spike_folder, summary_plot_folder, Params)
%% Finding the best cost parameter L for each recording
% Parameters
% ------------
% wavelet_spike_folder : (str)
% directory containing wavelet spike detection results.
% If you are not using wavelet spike detection, then lea... |
f5484425085dccb8f6cfe15c90a4c0cd3799d211bdb3c503cb42536b1c7cb394 | MATLAB | 34,883 | 833 | function twix_obj = mapVBVD(filename,varargin)
% Reads Siemens raw .dat file from VB/VD MRI raw data.
% requires twix_map_obj.m & read_twix_hdr.m
%
%
% Author: Philipp Ehses (philipp.ehses@tuebingen.mpg.de)
%
%
% Philipp Ehses 11.02.07, original version
% [..]
% Philipp Ehses 22.03.11, port to VD11... |
b8bf5d4f1decaade48d2cb9a3751ce7ad6d6b869c94de324d0dd71a483fb9b30 | MATLAB | 35,013 | 930 | function [A, W] = fpica(X, whiteningMatrix, dewhiteningMatrix, approach, ...
numOfIC, g, finetune, a1, a2, myy, stabilization, ...
epsilon, maxNumIterations, maxFinetune, initState, ...
guess, sampleSize, displayMode, displayInterval, ...
s_verbose);
%FPICA - Fixed point ICA. Main algorithm of FASTICA.
... |
570812a1faa603f713a07c81f78a201749657e18e6285a6bdd455047d178dc9f | MATLAB | 35,284 | 654 | % pop_eventinfo() - GUI for BIDS event info editing, generated based on
% fields of EEG.event
%
% Usage:
% >> [EEG, eInfoDesc, eInfo] = pop_eventinfo( EEG );
%
% Inputs:
% EEG - EEG dataset structure. May only contain one dataset.
%
% Optional i... |
3e006cec10c84fe770177939f28e69d58e1b19176f0251a1723f81db7be53b7f | MATLAB | 35,308 | 739 | % POP_STUDY - create a new STUDY set structure defining a group of related EEG datasets.
% The STUDY set also contains information about each of the datasets: the
% subject code, subject group, experimental condition, and session. This can
% be provided interactively in ... |
a99da0e04759b754fbaa1ed66de1a8b26156c3d61a9c6349d193e615c25e7665 | MATLAB | 35,352 | 715 | % POP_ERPIMAGE - draw an ERP-image plot of a given EEG channel or independent
% component. Uses a pop-up window if less than three (or four
% in one condition) input arguments are supplied. Calls ERPIMAGE.
% For further details see >> help erpimage
% Usage:
% >> po... |
c5efea67b7b6973cd8a7280846fcd3d5cd3e8ac2d6f6bcec5ef868ca4d61c7c6 | MATLAB | 35,368 | 819 | clear all; %176-181
close all;
clc;
AllFileName=[""];
for num_file=1:length(AllFileName)
AmpChannel0=1; AmpChannel1=2;
%%%%%%%%%%%%%%% menu %%%%%%%%%%%%%%%
AmpChannel=AmpChannel0;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
FileName=AllFileName{num_file};
load(['Mat Data/',FileName,'.mat']);
load(['Labnote/Labnote.mat']... |
db30613745cad06466fe513f381dc268b9808cef5b0f7d17d63755dd4d65f0fc | MATLAB | 35,873 | 1,191 | function coactPaper_figure06()
labelWeight=true;
labelCase=false;
labelSize=9;
letGapX=5;
letGapY=5;
fontsize=6;
close all
fh=initFig('width',18.6,'height',12.5,'font','Arial','fontsize',fontsize);
x=19;y=2;
panel_01(x,y,fontsize);
panelLetter2(x-letGapX-12,y-letGapY+4,alphabet(1,labelCase),'fontSize',labelSize,'isBo... |
77b4604ba0dfd08a33d0a5d5cd3d7dc0966fc14a3ee11a79f480c7b5d4583eaf | MATLAB | 35,934 | 573 | % POP_PRECLUST - prepare STUDY components' location and activity measures for later clustering.
% Collect information in an interactive pop-up query window. To pre-cluster
% from the commandline, use STD_PRECLUST. After data entry into the pop window,
% selected measur... |
66706afa1b6e9ad21c8dfc973be63ec68c21a775ead295d72d5757e2c37484b7 | MATLAB | 36,006 | 927 | function TOL_fig_stats1(config,params,dat)
% TOL_fig_stats1, comparison of Tolman et al. (1946) to other suburst maze studies
% Figure 3 for: Duvelle and Grieves (2026) Tolman's Sunburst Maze 80
% years on: A meta-analysis reveals poor replicability and little evidence for
% shortcutting. European Journal of Neurosci... |
fdb79275986173defee4979032fca9dcd852940b69df46094e3476aedd7c5921 | MATLAB | 36,081 | 826 | function [x, cost, info, options] = trustregions(problem, x, options)
% Riemannian trust-regions solver for optimization on manifolds.
%
% function [x, cost, info, options] = trustregions(problem)
% function [x, cost, info, options] = trustregions(problem, x0)
% function [x, cost, info, options] = trustregions(problem,... |
cd47377823de488e88e9280578a015f3083d6e51d2734505dcf4646b6e1e5183 | MATLAB | 36,184 | 442 | function osp_iniLoadWindow(gui)
%% osp_iniLoadWindow
% This function creates the initial load window in the gui.
%
%
% USAGE:
% osp_iniLoadWindow(gui);
%
% INPUT: gui = gui class containing all handles and the MRSCont
%
% OUTPUT: Changes in gui parameters and MRSCont are written into the
% ... |
4ad65670c7dd3705743e8ec99a0c890e2bb705da56068d2876f4712368416090 | MATLAB | 36,196 | 910 | function handles = distributionPlot(varargin)
%distributionPlot creates violin plots for convenient visualization of multiple distributions
%
% SYNOPSIS: handles = distributionPlot(data,propertyName,propertyValue,...)
% handles = distributionPlot(ah,...)
%
% INPUT data : m-by-nData array of values, or vector ... |
8a9ceb44e54ca8255893672126edf8e5e3c0fec8a7a027010509ea6af077f7ec | MATLAB | 36,255 | 771 | function [err, fstat, intensity_new, dfterm_new, dfdenom, tnames_new, LC] = SumsOfSquares(y, NF, FL, ntot, nterms, Qd, s, sindices, dfbothSS, modw, modwo, tnames, dfterm, dfe, dsgn, N_Brik, Contr)
%
% [err,] = ss.m ()
%
%Purpose:
%
%
%
%Input Parameters:
%
% y: values from all factor combinations at one voxel in vec... |
d14aaa8ef7f9c4e84f7c63075057e18708ce3b34f35aca49da81058dd1512c27 | MATLAB | 36,365 | 1,106 | function coactPaper_figure09()
labelWeight=true;
labelCase=false;
labelSize=9;
letGapX=7;
letGapY=4;
fontsize=6;
close all
fh=initFig('width',12.7,'height',16.5,'font','Arial','fontsize',fontsize);
x=11.5;y=8;
panel_01(x,y,fontsize)
panelLetter2(x-letGapX-3,y-letGapY-2,alphabet(1,labelCase),'fontSize',labelSize,'isBo... |
3fe9559466dc58afd4f5013d5bd8ab037ee595803dfaf0816a92793ec025cd67 | MATLAB | 36,489 | 991 | %% MEANAP Sensitivity Analysis
addpath(genpath('/home/timothysit/AnalysisPipeline/Functions'))
% This script asks what is the smallest difference in network
% metrics that can be detected by MEA-NAP
numNodes = 60;
numRandomNetworks = 100;
p = 0.1;
G = rand(numNodes,numNodes) < p;
G = triu(G,1);
% Make the graph symmetr... |
3c4f0a15ff466900f2c9ad3e9a318ade11f5fa20848ab5f0e09e8577006254d5 | MATLAB | 36,847 | 864 | %% ########################################################################
% demo_analysis_1_1_plot_ripples_1_f.m
% #########################################################################
%
% Main analyses on simulated data. Yields plots utilized in Fig. 1.
%
% -----------------------------------------------------... |
1a00188e567ec680e67d6d919a29e049d31271e5d0c944cd597e1c20f10c1e73 | MATLAB | 36,870 | 799 | classdef BasicPipelineTests < matlab.unittest.TestCase
properties
% log outputs
logFileName = 'summary_log.txt';
failedOpFileName = 'failed_operations_benchmark.txt';
footer = [repmat('=', 1, 62), '\n'];
% benchmarking files
precomputedMatNameOG = 'HCTSA_Bonn_EEG_OG.... |
13a00db59a543dce84aaaee4e3485048097c87921b5d0309b12a2abb477408cc | MATLAB | 36,994 | 1,028 | function ft_write_data(filename, dat, varargin)
% FT_WRITE_DATA exports electrophysiological data such as EEG to a file.
%
% Use as
% ft_write_data(filename, dat, ...)
%
% The specified filename can contain the filename extension. If it has no filename
% extension not, it will be added automatically.
%
% Additional ... |
9208d92b3490db190cee0f77ec1bf48b166b7ba511f13388c523a3765392c7f1 | MATLAB | 37,002 | 586 | classdef OspreyGUI < handle
%% OspreyGUI
% This class creates a one-in-all figure with visualizations of the
% processed data (spectra in the frequency domain), voxel coregistration
% and segmentation, quantification tables, and results.
%
% The figure contains several tabs, not all of which may be available at... |
6f73161b1c6278800d4e0aca0dac2e3b5d92cd891a306a8aab52c72931e55c10 | MATLAB | 37,126 | 864 | %% [chi,localField,totalField,fieldmapSD]=SepiaIOWrapper(inputDir,outputDir,varargin)
%
% Input
% --------------
% input : input directory contains NIfTI files or structure containing filenames
% output : output directory that stores the output (susceptibility map)
% maskFullName : mask filename... |
622f3d9879b3450a91609c26519a15fac1d905f938c33eaf8fe9a648114a63a1 | MATLAB | 37,150 | 660 | function [err, Contr] = ContrVec(order, n, NF, group, dmat, Contr, FL, num_col)
%
% [err,] = ContrVec.m ()
%
%Purpose:
%
% Obtain a vector for each contrast so that effect size is calculated in SumsOfSquares.m
%
%Input Parameters:
%
%
%
%Output Parameters:
% err : 0 No Problem
% : 1 Problems
%
%
%
%Key Ter... |
c5457ba7f4090d3570954131c0f42b6f9c883e3ab308f264e3130066eb5b8a19 | MATLAB | 37,190 | 895 | % HEADPLOT - plot a spherically-splined EEG field map on a semi-realistic
% 3-D head model. Can 3-D rotate the head image using the left
% mouse button.
% Example:
% >> headplot example % show an example spherical 'eloc_angles' file
% >> headplot cartesian % show an example cartesian '... |
85e38d1fa32f4b11ebc069cc9adbfdb775608b66067b44e3872ffa30bc2d78e8 | MATLAB | 37,384 | 785 | function [status] = ft_hastoolbox(toolbox, autoadd, silent)
% FT_HASTOOLBOX tests whether an external toolbox is installed. Optionally it will
% try to determine the path to the toolbox and install it automatically.
%
% Use as
% [status] = ft_hastoolbox(toolbox, autoadd, silent)
%
% autoadd = -1 means that it will c... |
c3ad9d1d449a3f0092cd76952e926fa875b99a687670e339614f0931502555e6 | MATLAB | 37,408 | 965 | %script IndiAna
%
%
%
%Purpose:
% Run 3dDeconvolve in an interactive user-friendly way.
%
%Input:
% Major ones are done through keyboard, while rare ones such as -censor , -nforist, etc. are left for user to implement.
%
%Output:
% Wave functions from waver;
% Various output files from 3dDeconvolve
%
%Key Terms:
%... |
62d35ddef0be05ab48f839a4f0567d52c6ac2138eb9fdab3526636263c54a753 | MATLAB | 37,478 | 818 | function [FourModelsigthre]=arrange_nodal_Slope(indminNodalStrmdall,indminNodalindre,notenoughNodalStr,Pathnew,opt,scale,Pathnewplot,pthretype,result_name)
%reorder
roi_num=length(indminNodalindre);
edges=zeros(roi_num,roi_num);
cd(Pathnewplot);
reompr=[];
for i=1:roi_num
temres=indminNodalindre{i}.Modelsel... |
466c6f5a219f0ec4c58933c20a4bfc9c20c8b7d1bce05e0c387ba7edafc9292c | MATLAB | 37,630 | 838 | % STD_DIPPLOT - Commandline function to plot cluster component dipoles. Dipoles for each
% named cluster is displayed in a separate figure. To view all the clustered
% components in the STUDY on the same figure (in a separate subplot), all
% STUDY clusters must be reque... |
1f4dd1196b564026fff7b7f905d311ffe37c5a8e6d6b169835297074425172c0 | MATLAB | 38,042 | 1,022 | % Meta_Activation_FWE(meth)
%
% This function sets up an MKDA analysis, starts or adds iterations, and
% retrieves and plots results. It has four modes, specified by the first input argument:
%
% 'setup' : Create activation map and save MC_SETUP file in current directory
% 'mc' : Add iterations and save in MC_I... |
26e28ff2104b30452b0d9891a1b8716ec48d0e920d4bca260a1374c22ae8b1ef | MATLAB | 38,407 | 1,217 | function varargout = studyplot(Method,varargin)
% function varargout = studyplot(method,coordinate list file,argument for selection,plothandle (string))
%
% method 'slices' or 'slices2'
% [dist,voxelcoord,plothandles,contourhandles] = studyplot('slices');
%
% method 'glass' or 'glassvert'
% [dist,brainhandle,linehandle... |
d3b330a8e1d7a669715be9366c4cebfa3c72ceefcbd70ee9e9b3d14f656bbb45 | MATLAB | 38,441 | 787 | function [K,Mx,xe] = apxGrid(cov, xg, hyp, x, z, b)
% apxGrid - Covariance function approximation based on an inducing point grid.
%
% A grid covariance function k(x,z) is composed as a product
% k(x,z) = k1(x(i1),z(i1)) * .. * kp(x(ip),z(ip)) of p covariance functions
% operating on mutually disjoint components of th... |
af1fdef2399d3569f897d814108e1a0f4423f402dc3bd48c593c9114c932e5ef | MATLAB | 38,442 | 682 | %% Script to compute HC and SSD MIND gradients.
% Copyright (C) 2026 University of Seville
% Written by Natalia García San Martín (ngarcia1@us.es)
% This file is part of Hierarchy Longitudinal MIND Gradients Psychosis toolkit.
%
% Hierarchy Longitudinal MIND Gradients Psychosis toolkit is free software:
% ... |
3b3f8803c6872a2cd1975d97f1d83f9ecaf0623360cf5fc298283127194bd6ca | MATLAB | 38,703 | 1,014 | function [fname] = sourceFeatures_ofc(ops)
%generates building blocks of features from OFC data.
%options for how the feature coding will be done
nsamp = ops.nsamps; %how many bootstrap for ARI samples will be made?
useZscore = ops.usezscore;
bootstrap_proportion = ops.bootstrap_proportion... |
3cce063b5421541f7ff4ad7fc79d5a9feacbe215c221f595a70519a15084b8f5 | MATLAB | 39,028 | 735 | function out = osp_plotMeanSpec(MRSCont, which_spec, g, shift,group, xlab, ylab, figTitle,basis)
%% out = osp_plotMeanSpec(MRSCont, which_spec,g, shift, xlab, ylab, figTitle)
% Creates a figure mean and standard deviation of the spectra. If the
% chosen spectra was fitted the mean fit, baseline and residue are show... |
025729d0ee8cdcbe51821b9530d95db074d0bf8cdf9d3ffe5ca27520e15e3116 | MATLAB | 39,072 | 878 | function [FourModelsigthre]=arrange_nodal_Slope(Nodal_metric,indminNodalStrmdall,indminNodalindre,notenoughNodalStr,Pathnew,opt,scale,Pathnewplot,pthretype,result_name)
%reorder
roi_num=length(indminNodalindre);
edges=zeros(roi_num,roi_num);
cd(Pathnewplot);
reompr=[];
for i=1:roi_num
temres=indminNodalindr... |
99c1360c68d15d8ba698aaf15738bf02c7c1b49857bf3fb750e93d6fb7387119 | MATLAB | 39,160 | 709 | function K = apx(hyp,cov,x,opt)
% (Approximate) linear algebra operations involving the covariance matrix K.
%
% A) Exact covariance computations.
% There are no parameters in this mode.
% Depending on the sign of W, we switch between
% - the symmetric Cholesky mode [1], where B = I + sqrt(W)*K*sqrt(W)... |
ccb6721017b40ea88c58bc46e5f31667c7d6aba81bf83eecce80ca2f0f1b2ce4 | MATLAB | 39,220 | 954 | function varargout = BrainNet_LoadFiles(varargin)
%BrainNet Viewer, a graph-based brain network mapping tool, by Mingrui Xia
%Function to load files for graph drawing
%-----------------------------------------------------------
% Copyright(c) 2017
% State Key Laboratory of Cognitive Neuroscience and Learning, Beijing N... |
7a18a15019e3504581ac1875d7bad0bbf753ee2879215dc25d8286ccf8d213ea | MATLAB | 39,265 | 968 | function stats=mes(X,Y,esm,varargin)
% ** function stats=mes(X,Y,esm,varargin)
% computes measures of effect size or related quantities between two
% samples (2-sample analyses) or one sample and a null value (1-sample
% analyses). The output consists of effect size measure(s), t statistics,
% and 95% confidence interv... |
4094b4977658d98ffff47b3311b66f5d05d87be76c2b5f836ef241579611fb92 | MATLAB | 39,930 | 528 | function osp_iniOverviewWindow(gui)
%% osp_iniOverviewWindow
% This function creates the initial overview window in the gui.
%
%
% USAGE:
% osp_iniOverviewWindow(gui);
%
% INPUT: gui = gui class containing all handles and the MRSCont
%
% OUTPUT: Changes in gui parameters and MRSCont are wri... |
723882bf40eb71cc204db95adf774114130b3a010906550625ecf017b6339924 | MATLAB | 40,013 | 900 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% DeepSqueak 2.7.0 %
% Copyright (c) 2021 Kevin Coffey , Ruby Marx, & Robert Ciszek %
% %
% Licensed under th... |
de4b979eca6e67800ea4fe179d52ef6a0d75607d3ef7858a30ab61e38d347b6a | MATLAB | 40,117 | 819 | function physio = tapas_physio_new(default_scheme, physio_in)
% Creates complete PhysIO structure fed into tapas_physio_main_create_regressors
%
% physio = tapas_physio_new(default_scheme, physio_in)
%
% IN
% default_scheme - if set, default values for structure entries are set
% according t... |
de5cc44ea2ded818e0656f489f54a083a35d94138f21615bcea6eb543442cc95 | MATLAB | 40,471 | 1,031 | function [MRSCont] = OspreyJob(jobFile,GUI,debug)
%% [MRSCont] = OspreyJob(jobFile)
% This function loads the Osprey job defined in jobFile.
% The job can be submitted in the following formats:
% - .m
%
% A valid Osprey job contains four distinct classes of items:
% 1. basic information on the MRS seq... |
70fb0c6b57c801378caebddd99c68ca880ee41338ed0c4e255167fc983a36306 | MATLAB | 40,707 | 1,069 | %===============================================================================
% Version JMCC PLUS (DOI: XXX)
% Author: Amin Forouzandehmehr
%===============================================================================
function [dY, dati] = hiMCES2026(time, Y, contrflag, GAC, stimFlag, freq, classicVSoptic, ... |
59cac2e38bec5a95f699aa0c3e8090bcdb5dd4abc07d9ce56dff8a5536381fc4 | MATLAB | 41,012 | 1,283 | function [output] = colormaplines
output = [
0 0.4470 0.7410
0.8500 0.3250 0.0980
0.9290 0.6940 0.1250
0.4940 0.1840 0.5560
0.4660 0.6740 0.1880
0.3010 0.7450 0.9330
0.6350 0.0780 0.1840
0 0.4470 0.7410
0.8500 0.3... |
58c80e9c7afc4bd886a5c14d0e470f0ceb8f80cef9fb559c4f05fb6f6986704c | MATLAB | 41,124 | 940 | % COREGISTER - Co-register measured or template electrode locations with a
% a reference channel locations file. For instance if you
% want to perform dipole modeling you have to coregister
% (align) your channel electrodes with the model (and the
% easi... |
28b9f2e715d0ecc905f1b6f5c0966080ab673cdd8a1afd88f9b6946cd5fb9ba2 | MATLAB | 41,272 | 692 | function [MRSCont] = osp_fitInitialise(MRSCont)
%% [MRSCont] = osp_fitInitialise(MRSCont)
% This function initialises default basis sets and decides which
% metabolites to include in the modeling process carried out by OspreyFit.
%
% USAGE:
% [MRSCont] = osp_fitInitialise(MRSCont);
%
% INPUTS:
% MRS... |
27facf24db61c333279ae2ce5ab160bf9ca1eb5178983d94683594d2e3ce852d | MATLAB | 41,480 | 850 | function [MRSCont] = OspreySeg(MRSCont)
%% [MRSCont] = OspreySeg(MRSCont)
% This function checks whether the structural image that the voxels were
% coregistered to in OspreyCoreg has already been segmented by SPM12.
%
% If it has not been, OspreySeg will call the SPM12 "New Segment"
% function to perform segme... |
5663b59627f53e811f4f99b6efad67f3a9ff7b5d2a1e85661a8a3b61c0dfd9d5 | MATLAB | 41,480 | 1,061 | % RUNICATEST - Perform Independent Component Analysis (ICA) decomposition
% using natural-gradient infomax - the infomax ICA algorithm of
% Bell & Sejnowski (1995) with the natural gradient method
% of Amari, Cichocki & Yang, the extended-ICA algorithm
% of Lee, Girolami &... |
2d52eaf34311fc085c080b4245d333e78461c549c43578567e9446d0e74a1fe5 | MATLAB | 41,891 | 1,052 | function source = ft_read_cifti(filename, varargin)
% FT_READ_CIFTI read functional data or functional connectivity from a cifti-1 or
% cifti-2 file. The functional data can consist of a dense or a parcellated
% representation. The geometrical description of the brainordinates can consist of
% triangulated surfaces or... |
308defeb278ebe9b7a1279ec6940fd28b16d0196c7f4eadbc998e0c081b33605 | MATLAB | 42,018 | 822 | % pop_participantinfo() - GUI for BIDS participant info editing
%
% Usage:
% >> [EEG, pInfoDesc, pInfo] = pop_participantinfo( EEG );
%
% Inputs:
% EEG - EEG dataset structure. May only contain one dataset.
%
% STUDY - (optional) If provided, subject and g... |
1f1431f57e6e5e86766d4735bd6cf0c1cda34bcb81410a48e9fa656857b6e007 | MATLAB | 42,167 | 993 | % SPECTOPO - Plot the power spectral density (PSD) of winsize length segments of data
% epochs at all channels as a bundle of traces. At specified frequencies,
% plot the relative topographic distribution of PSD. If available, uses
% PWELCH from the Matlab signal processing toolb... |
369f5ab3fe118eece1f3432d34c50cd3399648f17e20edf828a9ba04377c9cc7 | MATLAB | 42,391 | 689 | function [features, other_features]=ComputeTICAFeatures(StudyFolder, GroupAverageName, SubjListName, ...
fMRIListName, OutputfMRIName, tICAdim, ...
fMRIProcString, tICAFeaturesProcString, ...
... |
34cf0be91e77d7e637e927118dde790c9b27266688c21a625c2f35a5fd757e8c | MATLAB | 42,596 | 716 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%% BREATHING FILTER DETECTION TASK %%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% -------------------------------------------------------------------------
% Author: Olivi... |
a68a5598faa4550d9f87ffbf107fd0f192934393058627bbae35fd33b0a2df2c | MATLAB | 42,735 | 1,170 | function [x,f,exitflag,output] = minFunc(funObj,x0,options,varargin)
% [x,f,exitflag,output] = minFunc(funObj,x0,options,varargin)
%
% Unconstrained optimizer using a line search strategy
%
% Uses an interface very similar to fminunc
% (it doesn't support all of the optimization toolbox options,
% but supports ... |
18c2766e69c15beac49db902b981888432ea648d5f550607bf90562d4fa0a4da | MATLAB | 43,274 | 1,066 | %io_loadspec_twix.m
%Jamie Near, McGill University 2014.
%Edits from Franck Lamberton, 2017.
%
% USAGE:
% out=io_loadspec_twix(filename);
%
% 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).
%
% op_loadspec_... |
0099ee41c67edb8ee362c05b54bd38c2d6647ea714cd073a0d13522f261c23b9 | MATLAB | 43,299 | 1,097 | % 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, Girola... |
11befbba378c68f724ce73340a8074870ee6539267f17f455b3552e34770c804 | MATLAB | 43,332 | 1,335 | function coactPaper_figureS24()
labelWeight=true;
labelCase=false;
labelSize=9;
letGapX=9;
letGapY=5;
fontsize=6;
close all
fh=initFig('width',18.6,'height',9.5,'fontsize',fontsize);
x=12;y=6;
panel_01(x,y,fontsize);
panelLetter2(x-letGapX,y-letGapY,alphabet(1,labelCase),'fontSize',labelSize,'isBold',labelWeight)
dr... |
60cbf623c75cf5234f6649c51e27cf31a161434a3f39804e6caed22ef02c474f | MATLAB | 43,490 | 1,129 | % TIMEF - Returns estimates and plots of mean event-related spectral
% perturbation (ERSP) and inter-trial coherence (ITC) changes
% across event-related trials (epochs) of a single input time series.
% * Uses either fixed-window, zero-padded FFTs (fastest), wavelet
% 0-padded DFT... |
74ffa3c5ae500b4a4e9038f234ea7cc6442a64f769776d3f3acd760efd79f62d | MATLAB | 43,600 | 940 | function varargout = AssemblyGui(varargin)
% ASSEMBLYGUI MATLAB code for AssemblyGui.fig
% ASSEMBLYGUI, by itself, creates a new ASSEMBLYGUI or raises the existing
% singleton*.
%
% H = ASSEMBLYGUI returns the handle to a new ASSEMBLYGUI or the handle to
% the existing singleton*.
%
% ASSEMBLYG... |
3dd44d23a2cda143b82dcd484cf7783c175c7bdaf17cb8b811778d5ddf172aa7 | MATLAB | 44,015 | 1,112 | % 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, Girola... |
2010cf27e9013e9888238e12b7bc246a68f838f251f271ff3f991e15b201ea89 | MATLAB | 44,166 | 1,112 | % 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, Girola... |
20d7a1a81fe5c943e305aaaf3912101230aafda7d6f57fed603f74ad95b54c7c | MATLAB | 44,624 | 1,248 | function varargout = legendflex(varargin)
%LEGENDFLEX Creates a more flexible legend
%
% legendflex(M, param1, val1, ...)
% legendflex(h, M, param1, val1, ...)
% [legend_h,object_h,plot_h,text_str] = legendflex(...)
%
% This offers a more flexible version of the legend command. It offers a
% different method of posit... |
75d3de54973c493450b7149675bb74721fd9ffcb4072d1296b88d722235dc2d6 | MATLAB | 45,118 | 1,027 | DATApath='../DATA/';
DATAdir={'D_day1',
'D_day2',
'D_day3',
'D_day4',
'D_day5',
'D_day6',
'D_day7',
'D_day8',
'D_day9',
'A_day1',
'A_day2',
'A_day3',
'A_day4',
'A_day5'};
% the Amygdala further segmented into centromedial (AA, CeA, CoA, SI) and ba... |
fd01ae8e053e80d94323b4b063af1e7a7a2d3d0d4dc8e7add35e96bb64899f5f | MATLAB | 45,118 | 1,027 | DATApath='../DATA/';
DATAdir={'D_day1',
'D_day2',
'D_day3',
'D_day4',
'D_day5',
'D_day6',
'D_day7',
'D_day8',
'D_day9',
'A_day1',
'A_day2',
'A_day3',
'A_day4',
'A_day5'};
% the Amygdala further segmented into centromedial (AA, CeA, CoA, SI) and ba... |
22712cb72cf45c3088613ec994ebf64907c147886ceef248723f05136b852a53 | MATLAB | 45,331 | 1,420 | function coactPaper_figure04()
labelWeight=true;
labelCase=false;
labelSize=9;
letGapX=5;
letGapY=6;
fontsize=6;
close all
fh=initFig('width',18.6,'height',16,'font','Arial','fontsize',fontsize);
x=8+9;y=3;
panel_01(x,y,fontsize);
panelLetter2(x-letGapX-9,y-letGapY+4,alphabet(1,labelCase),'fontSize',labelSize,'isBol... |
61b5f5967de270346db7f92dfff9f406760f246028a8626891003bc1f2cfca26 | MATLAB | 46,060 | 882 | function RestingStateStats(motionparameters,hp,TR,ICAs,noiselist,wbcommand,inputdtseries,bias,outprefix,dlabel,bcmode,outstring,WM,CSF)
% function RestingStateStats(motionparameters,hp,TR,ICAs,noiselist,wbcommand,inputdtseries,bias,outprefix,dlabel,bcmode,outstring)
%
% Script for decomposing the CIFTI time series... |
4a2dd15b8e7c25a70b81c9ea3877cfe633d7fefe77dbacc1cc7f14f0c3ace184 | MATLAB | 46,771 | 1,557 | function out = uipickfiles(varargin)
%uipickfiles: GUI program to select files and/or folders.
%
% Syntax:
% files = uipickfiles('PropertyName',PropertyValue,...)
%
% The current folder can be changed by operating in the file navigator:
% double-clicking on a folder in the list or pressing Enter to move further
% dow... |
998e5309c5c35f77f8b960152bd77b20647599c73330b93f99d146551e86e367 | MATLAB | 47,006 | 1,298 | function varargout = spider_plot_R2019b(P, options)
%spider_plot_R2019b Create a spider or radar plot with individual axes.
%
% Syntax:
% spider_plot_R2019b(P)
% spider_plot_R2019b(P, Name, Value, ...)
% h = spider_plot_R2019b(_)
%
% Documentation:
% Please refer to the MathWorks File Exchange or GitHu... |
1db3b99f7cb18a78a175dd022e0524301519e4df87c7a1b082eddbd7aad7c091 | MATLAB | 47,213 | 1,346 | function coactPaper_figure07()
labelWeight=true;
labelCase=false;
labelSize=9;
letGapX=5;
letGapY=6;
fontsize=6;
close all
fh=initFig('width',18.6,'height',12.5,'font','Arial','fontsize',fontsize);
x=9;y=5;
panel_01_02_03(x,y,fontsize);
panelLetter2(x-letGapX-3,y-letGapY+2,alphabet(1,labelCase),'fontSize',labelSize,'... |
92b23ca7011c1ce21408b06559cebe4feb9a4b6f09f9dc96b7ae5420a83617c8 | MATLAB | 47,508 | 1,078 | DATApath='../DATA/';
DATAdir={'D_day1',
'D_day2',
'D_day3',
'D_day4',
'D_day5',
'D_day6',
'D_day7',
'D_day8',
'D_day9',
'A_day1',
'A_day2',
'A_day3',
'A_day4',
'A_day5'};
% the Amygdala further segmented into centromedial (AA, CeA, CoA, SI) and ba... |
58c45482315d384eb987cdf91d9412e29822cd16d9ce831cb16418d83ac91667 | MATLAB | 47,594 | 1,079 | DATApath='../DATA/';
DATAdir={'D_day1',
'D_day2',
'D_day3',
'D_day4',
'D_day5',
'D_day6',
'D_day7',
'D_day8',
'D_day9',
'A_day1',
'A_day2',
'A_day3',
'A_day4',
'A_day5'};
% the Amygdala was further segmented into centromedial (AA, CeA, CoA, SI) an... |
f4660f590c3abcce6a0237803dad427ca8fa43e5dec81edc92421a61ec8a0e8b | MATLAB | 48,171 | 1,241 | 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 is a list of ... |
d77a1bf5a6c682d0abf94e168b4dafdafefdbc6a1448c3e870085a09ecf1c3b6 | MATLAB | 48,503 | 977 | % function to show limo results - deprecated
% Copyright (C) 2016 Ramon Martinez
%
% This file is part of EEGLAB, see http://www.eeglab.org
% for the documentation and details.
%
% Redistribution and use in source and binary forms, with or without
% modification, are permitted provided that the following conditions ar... |
08bfef842869171b81a79104d6a95bd0b328a8317bde0051548ee97df31fdd70 | MATLAB | 48,983 | 639 | function plot_distractor_modulation_neural_activity_task_var_cell
close all
clear all
clc
% Plot distractor modulations of trial-type-selective neurons for each task variable.
% Select a folder containing data.
folder_name = uigetdir;
cd(folder_name)
% Control.
load('activity_control.mat')
activity = activity_contro... |
475354ba3ad98558cbef117e82ab7ce3e70a6f6b86209c08f302407cb1916b2e | MATLAB | 49,600 | 1,030 | function varargout = TMStargetFC(varargin)
% TMSTARGETFC MATLAB code for TMStargetFC.fig
% TMSTARGETFC, by itself, creates a new TMSTARGETFC or raises the existing
% singleton*.
%
% H = TMSTARGETFC returns the handle to a new TMSTARGETFC or the handle to
% the existing singleton*.
%
% TMSTARGET... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.