sha256 stringlengths 64 64 | language stringclasses 28
values | size int32 1 491k | lines int32 1 23.2k | content stringlengths 1 200k |
|---|---|---|---|---|
a3ca903e355fd5bd253412d2d9d21381ba84ce3030d710aeb8d7520a47346271 | MATLAB | 4,846 | 137 | %% Determine correct/incorrect responses for MEG data.
%% Revisions: how to deal with no reponse
%% Just get the data from one file
load('20140806T101303_taPilot1.mat');
trialCount = 8;
respSecs = 2;
refreshRate = 60;
blockLength = 840; % in frames
cueLeft = {1 4};
cueRight = {2 8};
maxCue = max(max(cell2mat(cueLe... |
0f37b3bc41571719b13c0d83c13f73f289acc4c4acd27160f3ffd198849fa25d | MATLAB | 4,849 | 126 | function [tMin,fMin,tBreak1,tBreak2,tMinAll]=essential_distMinAnglePair_base(Q211,Q212)
flagCheckFirstDer=true;
flagUseNewton=true; %Note: requires flagCheckFirstDer=true
tolMZero=1e-15;
tMinAll=[];
[tBreak1,~,~,c1,m1,p1]=essential_distMinAnglePair_discontinuityDistance(Q211);
[tBreak2,~,~,c2,m2,p2]=essenti... |
c54c32a4df93832f7ebfc6be6c5d0faf30818b834323b24f8f18655d426af7e9 | MATLAB | 4,851 | 129 | function [nsynapses,imdata,syndata] = segment_cc_multiplexed(fov,params)
% Automated synapse segmentation from multi-ExR data
% This script has not been updated/maintained since June 2022
% Please contact Margaret at mschro@mit.edu if you want to collaborate on
% this, but it was deprioritized before manuscript submiss... |
b819c54448f507f66d70d76b037a628214ab0a7d3fa2cee93c7f794c755e6462 | MATLAB | 4,852 | 231 |
function LAN = fourier_ind(LAN, Win,Point, Fre,bin, Norm, baseline,texto,output,boot,alpha,nrandom)
% v 0.9.2
% baseline [s1 s1]: segundos limites de la linea de base
%
% 16.05.2013 fix epocas vacias o malas
% 22.12.2009
% FALTA
% 0 --- ajustar para trial de duraci?n variable
% 0 --- ajustar linea d... |
d5fe1c0d4fbed0b9066ca42922d8f24050b51450d8594752dbd20059e9c5d1c8 | MATLAB | 4,852 | 134 | function CBIG_preproc_motion_outliers(DVARS_file,FDRMS_file,FD_th,DV_th,discard_seg,output_dir_name)
% CBIG_preproc_motion_outliers(DVARS_file,FDRMS_file,FD_th,DV_th,discard_seg,output_dir_name)
%
% This function is used to find the outliers with DVARS threshold DV_th and
% FDRMS threshold FD_th. After threholding, on... |
f02ec460d50580c091ad20ab91766a06bbe82ab2db819e1ada7ba60eb4e04548 | MATLAB | 4,852 | 163 | % Loads the raw iEEG data and creates an SPM file with all the neccesary variables to do further analysis such as peak statistics.
%% clear workspace
close all;
clear all;
clc;
%% load data into spm format
d = dir('data/iEEG');
if ~contains('spm_ecog.mat',{d.name})
alldata = importdata('data/iEEG/WakefulnessMatl... |
db05824e78fe04a3a982aacf8d3077d616d400e0353b720645df1d2ad705627b | MATLAB | 4,854 | 139 | % Three-point stencil on the unit line, constant-coefficient Poisson equation,
% Dirichlet boundary conditions.
%
% This is basically the 1D analogue of FD_SQUARE1X. Note that MFX must be used
% since we do not have a special 1D version of MF2/MF3.
%
% Inputs (defaults are used if not provided or set empty):
%
% - N:... |
6b6c20a65666f80e705648134d716f277f6b31b89516c93792331ba4b062704b | MATLAB | 4,855 | 101 | function [sortedStruct index] = nestedSortStruct(aStruct, fieldNamesCell, directions)
% [sortedStruct index] = nestedSortStruct(aStruct, fieldNamesCell, directions)
% nestedSortStruct returns a nested sort of a (one-dimensional) struct array
% (aStruct), and can also return an index vector. The fields by which to so... |
4de60764f41ed5065c1d051770be7a526e88ec119d9ce7058017bc68712cad95 | MATLAB | 4,856 | 170 | function [model, X, lambdaVec, opt] = logregFit(X, y, varargin)
% Fit a logistic regression model, (supports multiclass)
% INPUTS:
% X: N*D
% y: N*1 where y(i) in {1,..,C} or {0,1} or {-1,+1}
% or N*C where y(i,:) is a one-of-C encoding
% Dummy encoding only supported for multi-class case
%
% OPTIONAL INPUTS: (spe... |
ddf52291f4611713eff5d02a47d0cb163dff026e662318b0e201114aaf0d175f | MATLAB | 4,856 | 173 | % imageCheck.m
% load stimulus
blockOrder = order.blockOrder;
noise = p.noise;
stimSize = p.stimSize;
contrast = p.contrasts(1);
orientation = p.orientation;
spatialFreq = p.spatialFreq;
pixelsPerDegree = p.pixelsPerDegree;
blurRadius = p.blurRadius;
backgroundColor = p.backgroundColor;
iContrast = 1;
for iPhase = 1... |
e2e475d77f7e0c44bf5bd752662309292153a990abfc204652d3e942c074b8c5 | MATLAB | 4,857 | 121 | function out_P = m_eLORETA_nvr(sa, pattern, chanlocs_labs, pattern_name, ...
subject, cond, save_plot, save_format, dir_out, show_plot, colormap)
%% Calculate eLORETA for a given topography
% INPUT:
% sa leadfield info (read from 'sa_hyhead.mat')
% pattern vecto... |
edd11e9cb5c728da4404154293741cdad173424825afa79254546197889bd2a8 | MATLAB | 4,858 | 153 | function SplitReview(spkDat, splitDat, varargin)
% convert waveform data from int16 to double-precision floating point
spkDat.waves = double(spkDat.waves);
maxScale = 1;
sameScale = true;
convertToVolt = true;
nSampTarget = 100;
clustList = [splitDat.origId unique(splitDat.newId)];
nClust = length(clustList);
showIdx... |
2e6e34a9e5d1c12ada3e4021df1485a48e2b9d80f29b26038e4694f85ed03a79 | MATLAB | 4,859 | 109 | %% Efficient subpixel image registration by cross-correlation.
% Registers two images (2-D rigid translation) within a fraction
% of a pixel specified by the user. Instead of computing a zero-padded FFT
% (fast Fourier transform), this code uses selective upsampling by a
% matrix-multiply DFT (discrete FT) to d... |
24d0454c19de665eb60b44e7a2300cfe975275f2961a72667433a5e6f2827f45 | MATLAB | 4,860 | 134 | function bfsave(I, outputPath, varargin)
% BFSAVE Save a 5D matrix into an OME-TIFF using Bio-Formats library
%
% bfsave(I, outputPath) writes the input 5D matrix into a new file
% specified by outputPath.
%
% bfsave(I, outputPath, dimensionOrder) specifies the dimension order of
% the input matrix. Default... |
2ebc115efba8f6b57781befd983a362449feddfc4ea631fa078bd5289ead916c | MATLAB | 4,860 | 165 | function [LL,dLLdX,dLLdP,d2LLdX2,d2LLdP2,Ey,Vy] = VBA_evalAL(Xt,P,beta,ut,yt,options)
% smart wrapper for unnormalized log-likelihoods
% function [LL,dLLdX,dLLdP,Ey,Vy] = VBA_evalAL(Xt,P,ut,yt,options)
%
% This function evaluates the re-normalized log-likelihood at the observed
% data point. This is done by computing t... |
ce07825f34bf8c04d8ee7d1ecc67e400a415114d20682560c17a21b202f1ce3a | MATLAB | 4,860 | 178 | % Rao-Blackwellised particle filtering for jump Markov linear system
% We reproduce example B from Doucet, Gordon, Krishnamurthy
% "Particle filers for state estimation of Jump Markov Linear Systems", 2001.
% This concerns a target moving in 2d according to 3 different modes
% The code was written by Nando de Freitas a... |
18d0b3b7f57faadb6d6f1d5aeb1344e9b66789a4e5269f13dd03ed01170538dc | MATLAB | 4,867 | 153 | function fstats = lme_mass_F(stats,CM,prs)
% fstats = lme_mass_F(stats,CM,prs)
%
% Inference for the fixed-effects in the linear mixed-effects model. Allows
% to test a different model at each voxel/vertex (Depends on the Statistics
% toolbox).
%
% Input
% stats: Structure array containing statistiscs for every voxe... |
081c644500e7b158f8c1c4e397b954d3b678d0fce4873156ee9c6885bbf97065 | MATLAB | 4,868 | 123 | function [hdr] = read_brainvision_vhdr(filename)
% READ_BRAINVISION_VHDR reads the known items from the BrainVision EEG
% header file and returns them in a structure
%
% Use as
% hdr = read_brainvision_vhdr(filename)
%
% See also READ_BRAINVISION_EEG, READ_BRAINVISION_VMRK
% Copyright (C) 2003, Robert Oostenveld
%
... |
b502201a3f5e5674c62a448e2febdd9cca543eae1d297e004bfae8148e152119 | MATLAB | 4,868 | 193 | %load('Z:\apt\experiments\data\trnDataSH_20180503.mat');
%shinfo = importdata('Z:\apt\experiments\data\shflies.csv');
load('/groups/branson/bransonlab/apt/experiments/data/trnDataSH_20180503.mat');
shinfo = readtable('/groups/branson/bransonlab/apt/experiments/data/old/shflies.csv');
excludeflyids = importdata('/... |
6892a04f2972672c7780fc3831deaf6535672fd2394f88afd62b6cc220c9b1a2 | MATLAB | 4,869 | 124 | classdef AffineMap < diffgeometry.CoordinateMap
% Linear CoordinateMap defined by matrix in homogeneous coordinates
%---------------------------------------------------------------------
% license
%---------------------------------------------------------------------
% Copyright 2015 Idse Heems... |
8cdd473c995551b2cefab9a2a5cbe2396e61164a72efa14b80d784343248826f | MATLAB | 4,869 | 123 | function [hdr] = read_brainvision_vhdr(filename)
% READ_BRAINVISION_VHDR reads the known items from the BrainVision EEG
% header file and returns them in a structure
%
% Use as
% hdr = read_brainvision_vhdr(filename)
%
% See also READ_BRAINVISION_EEG, READ_BRAINVISION_VMRK
% Copyright (C) 2003, Robert Oostenveld
%
... |
1a6efb91988bc2ea4dabfaff061de605a78d0117f9d98fe84b6357c192146338 | MATLAB | 4,870 | 136 | % Clear workspace and command window
clear;
clc;
% Load the previously saved MAT file
load('Brain_Tumor_Research_Results.mat');
% Improve table names
Book_chapter = BookChapter;
Conference_paper = ConferencePaper;
clear ConferencePaper BookChapter;
% Assuming the types are loaded as variables, create a l... |
53e5d0d3b8d889f0f8f523497dfaa22606ea41e56e78705626cbe0f468003f43 | MATLAB | 4,870 | 161 | function [model, loglikHist] = ldsFitEm(data, nlatent, varargin)
%% Fit a linear dynamical system model via EM
% We do not estimate parameters associated with an input/ control sequence.
% We fix Q=I and R=diagonal.
% See ldsFit.pdf for details of the algorithm.
%
%% Inputs
% data - a cell array of observation ... |
5f4b3fe6784285cbbb7855f3e9649baec36997692b9f0be95fa54c98baacc7e2 | MATLAB | 4,870 | 112 | % Get period based control wheel slope data
% Edit by Jerry, 11/10/2022
function [wheelSopeData,CtrlInclude,CtrlExclude,wheelSopeInclude] = ...
GetCtrlWheelInfo_221110(params,szCell,szDir,szTiming,BLthd,SaveDir)
sps = params.SampleRate; % 1000
PreCtrlOffset = params.PreIctalOffset*sps; % baseline 60s*1000
... |
aa64cfb91f1888d9bb96c56ab1956c4324e34bc291b06cf5ebdc95995c6a1ea5 | MATLAB | 4,870 | 127 | function [pval F] = circ_htest(alpha1,alpha2,r1,r2)
% Parametric Hotelling paired sample test for equal angular means. Can be
% used as a paired-sample test for circular data. The test has 2 by N-2
% degrees of freedom where N is the number of pairs in the phase
% distribution.
%
% If the individual phase ... |
0cd09a4d04fc0a7be1cb071aa3a078c7493710ba0ff5001f540579148c6c7505 | MATLAB | 4,872 | 133 | function [dataout] = ft_electrodermalactivity(cfg, datain)
% FT_ELECTRODERMALACTIVITY estimates the electrodermal activity from a recording of
% the electric resistance of the skin.
%
% Use as
% eda = ft_electrodermalactivity(cfg, data)
% where the input data is a structure as obtained from FT_PREPROCESSING.
%
% The... |
58263ed7dea89ee02540b8787b3e69fb9d908a7a2dc8bf4ed0eeadfe907dfaac | MATLAB | 4,872 | 122 | function extract_replay_info_batch_cross_experiment_shuffled(folders)
shuffles ={'PRE spike_train_circular_shift','PRE place_field_circular_shift','POST place bin circular shift'...
,'POST time bin permutation','PRE cell_id_shuffle'};
for n = 1:length(shuffles)
[log_odd] = extract_ground_truth_info(folders,'c... |
29737331cd1a3e96c58941a5f16b412408994200cc2ae17884289bcc6d19e772 | MATLAB | 4,873 | 121 | clear
close all;
addpath(genpath('D:\Others_codes\Deep_learning\caffe-windows-master\matlab'))
addpath('D:\Codes\CSCNN\NLR_codes\NLR_CS');
addpath('D:\Codes\CSCNN\D-AMP_Toolbox');
rate = 0.01;
load('D:\Codes\CSCNN\CSCNN_test\phi_suhas\phi_0_10_1089.mat');
folder_model = 'D:\Codes\CSCNN\CSCNN_test\caffe_model\... |
3aff78b8b60e78737c60d04a1a985c53a48f5b89fa5027cb0e6908344f2d36c7 | MATLAB | 4,874 | 194 | % This small script looks in the direcory and checks if the images are there.
%
% This works only on Matlab 5.x (otherwise, the dir commands works differently)
% (c) Jean-Yves Bouguet - Dec. 27th, 1999
l = dir([calib_name '*']);
calib_path = fileparts(calib_name);
for i = 1:numel(l),
l(i).name = fullfile(calib_path... |
c6cd2f9157759e3dc3a6aee3689919ae9cfff75b464c48d8e4a9c7a4c896ed82 | MATLAB | 4,876 | 125 | clear c resvec its;
load(fullfile(patient_path,'dipoles',dipole_name, ...
strcat(patno,'_',model_name,'_',dipole_name,'_charge_solution_adapt')));
load(fullfile(patient_path,'dipoles', dipole_name, ...
strcat(patno,'_',model_name,'_',dipole_name,'_potentials_adapt')));
%% load additional colormaps
addpath(ful... |
5e7e15be2045e8d457a75522ada8961c163f7ac809807e5fc3e4f71684778d79 | MATLAB | 4,878 | 144 | function spkDat = ReloadWaves(spkDat, trodeFile, varargin)
[wL, nChan, nSpk] = size(spkDat.waves);
pk = double(spkDat.peakLoc);
wP = double(spkDat.wavePad);
wL = wL - 2*wP;
upsample = spkDat.upsample;
batchSize = 32768;
verbose = true;
whiten = false;
alignWin = spkDat.alignWin;
% convert wave parameters to ms
wL = 10... |
eaefc7ef73a97ad338f28479738516233cc3b0c3a70dca17e6679eeb82bb8a6a | MATLAB | 4,878 | 142 | % clear;clc;
% load('/Users/dianewang/Desktop/RfMRIHarmonization/scanner_harmonization/data_results/FCP/archived/600_subinfo.mat');
% r = Relabeling(Age,[21,40],3,Sex,0,2);
function labels = yw_Relabeling(varargin)
%% labels = Relabeling(varargin)
%Input
% vars - continuous variable, e.x age, education years, etc. n... |
4f84b4416da38e308b67097d69ca2d21b5137583ba5435e17243085cbeef9710 | MATLAB | 4,879 | 118 | function [trl, eventslist] = trialfun_MSIT_correct(cfg)
% SEARCHTASKTRIALFUN is the function that filters and organizes trials by
% the designated markers. This function is called by:
% main > fcp_1_taskepoching > ft_definetrial
%
% INPUTS:
% cfg.dataset - path to CTF dataset
% cfg.trialdef.t0marker... |
e3db6bba7a79a61d6f1f6f2b33c35ce9edb851fd823603868ca0cb956dd30aa9 | MATLAB | 4,879 | 122 | function [obj] = ft_convert_coordsys(obj, target, method, template)
% FT_CONVERT_COORDSYS changes the coordinate system of the input object to
% the specified coordinate system. The coordinate system of the input
% object is determined from the structure field object.coordsys, or needs to
% be determined and specified... |
a7d34e58a514364809a9cc08111340ff73f0edd1efab1e0cfabd701e87a74f2b | MATLAB | 4,880 | 133 | function [dataout] = ft_electrodermalactivity(cfg, datain)
% FT_ELECTRODERMALACTIVITY estimates the electrodermal activity from a recording of
% the electric resistance of the skin.
%
% Use as
% eda = ft_electrodermalactivity(cfg, data)
% where the input data is a structure as obtained from FT_PREPROCESSING.
%
% The... |
0e11d1fe23459aef117489aaac6c2edcca98c6c10383bcfe9a51836f7062a830 | MATLAB | 4,881 | 149 | function [tfr,t,f] = tfrgrd(x,t,N,g,h,rs,MoverN,trace);
%TFRGRD Generalized rectangular time-frequency distribution.
% [TFR,T,F]=TFRGRD(X,T,N,G,H,RS,MOVERN,TRACE) computes the
% Generalized Rectangular distribution of a discrete-time signal X,
% or the cross GRD representation between two signals.
%
% X : signal... |
d67a8487720f82eab745b6f5a41382e0ec555dc0aa9204fdecaebece9e68264e | MATLAB | 4,881 | 92 | function Settings=DefaultSettings()
%Load in all the default settings for the automated temporal analysis
%This will create a Settings data structure, which is fed into the various
%functions, who will take the components they need.
% Input: none
%
% Output: 'Settings' Datastructure containing a... |
31534d87a0a68b347d1eca8ccf9d79fb95a8c4c2e991dffdd71142286ac9c184 | MATLAB | 4,882 | 120 | % Interpret SVM Weights
%----------------------------------------
% Description:
% This function interprets the SVM weights for AI-optimized non-invasive
% brain stimulation dosing and treatment response prediction for major depression.
% It includes visualizations, statistical analyses, and ranking of regions of int... |
eeaf9f598e59bdcf200868013249e17522dc29e8984768beac7ff5145ea9df0e | MATLAB | 4,885 | 167 | function [ newevent, error ] = wlProc_fitFreqPhaseLinear( ...
hilfreq, hilphase, oldevent)
% function [ newevent, error ] = wlProc_fitFreqPhaseLinear( ...
% hilfreq, hilphase, oldevent)
%
% This function estimates oscillatory burst frequency and phase by curve
% fitting a linear ramp in the region of interest.
%
%... |
49e18f6509a56318b072e565ac87c45516466e0d43b8883faf4e8053e10dbf7a | MATLAB | 4,886 | 124 | function [vCA1_PET] = vCA1_PET_atlas(PET_scan,MRI_atlas)
save_imgs = 0;
%% Slices
% Column 1 - left
regions = cell(10,2);
regions{1,1} = [75 30;68 33;62 38;57 44;56 51;57 55;62 50;69 43;77 38]; %slice=99
regions{2,1} = [75 30;68 33;62 38;57 44;54 52;55 57;62 50;69 43;77 38]; %slice=98
regions{3,1} = [74 30;68 3... |
529965652195e653e9ffc49b99ff7af4ca1433e1d594a1fe301204beeab14e6c | MATLAB | 4,886 | 118 | function ydata = tsne_p(P, labels, no_dims)
%TSNE_P Performs symmetric t-SNE on affinity matrix P
%
% mappedX = tsne_p(P, labels, no_dims)
%
% The function performs symmetric t-SNE on pairwise similarity matrix P
% to create a low-dimensional map of no_dims dimensions (default = 2).
% The matrix P is assumed to be s... |
def0ac4f28114d9c84bce7b9324aa71fe5f7d3c2f01f2bc7a8f2daa48ea034d6 | MATLAB | 4,887 | 124 | clear all
direc = '/Users/caterinamagri/Documents/Projects/SMRProject/SPM/SMR_Analysis/4_preprocessedData_PSF/sub%s/GLM_mainExp_id/';
direcOutput = '/Users/caterinamagri/Documents/Projects/SMRProject/SPM/FromCosti/18ConjunctionAnalysis';
contrasts = [6 8];
subjects = [12];
file1dircon = strcat(direc,'con_00%02d.nii');... |
0efa99b73aa8b33ab51302132d519c84f95ee57dd92c1a93703828cc28bd5feb | MATLAB | 4,888 | 173 | function [str,cur_line] = struct2str(s,units,max_width,max_struct_elem, ident_str,total_ident_len,str,cur_line)
%
% AF 11/6/01
if (exist('units','var') ~= 1)
units = struct([]);
end
if (exist('max_width','var') ~= 1)
max_width = Inf;
end
if (exist('max_struct_elem','var') ~= 1)
max_struct_elem = 3;
end
if (... |
8f7136b55b41723fd09ecbaab8732292d8959cee288db953da12ec67b40b06a2 | MATLAB | 4,889 | 142 | function hs = ft_plot_headshape(headshape,varargin)
% FT_PLOT_HEADSHAPE visualizes the shape of a head from a variety of
% acquisition system. Usually the head shape is measured with a
% Polhemus tracker and some proprietary software (e.g. from CTF, BTi
% or Yokogawa). The headshape and fiducials can be used for coreg... |
b580c91e52f7a8ac92617decd059bfcf27d45c083ae9be5a03b6f874390215e5 | MATLAB | 4,889 | 144 | %{
## Run command locally:
workspace = getenv('WORKSPACE');
datafolder = [workspace, '/results/w3c_sim/mappers_test/'];
cohort_path = [workspace, '/data/w3c_subsampled/cohort.csv'];
timing_base_path = [workspace, '/data/w3c_subsampled/'];
output_dir = [workspace, '/results/w3c_sim/analysis/mappers_test/'];
circle_test... |
5b569475c4910edf5622959b6036916807fabe46d215bcc4020443a2c954c901 | MATLAB | 4,890 | 206 | % [snd data] = make_pbup_mixed3(R, gamma_dir, gamma_freq, srate, T, varargin)
%
% Makes Poisson bups
% bup events from the left and right speakers are independent Poisson
% events
%
% =======
% inputs:
%
% R total rate (in clicks/sec) of bups from both left and right
% speakers (r_L + r_R).
%
% gamma... |
81a4a58a15e41aaa2974e4f4f3245c7d9a2b6ad5c694cf3be673202f1ff5e980 | MATLAB | 4,892 | 138 | % Second-kind integral equation on the unit circle, Laplace double-layer.
%
% This example solves the Dirichlet Laplace problem on the unit disk by using a
% double-layer potential, which yields a second-kind boundary integral equation.
% The integral is discretized with the trapezoidal rule; the resulting matrix is
% ... |
9f923b82355239fc3186ce7d048b9809cc20818afa86d4d482d9ce932225bcbe | MATLAB | 4,892 | 154 | %% NVR Downsample and apply PREP
%
% Downsamples the data to 250Hz and applies PREP pieline.
% For details on the PREP pipe plese see:
% http://vislab.github.io/EEG-Clean-Tools/
%
% For the specific parameters used here, plese see below.
%
%
% 2017 & 2018 by Felix Klotzsche and Alberto Mariola
% 2024 update by Antoni... |
1b9accbe430bef7e2c4cb3ded854c257e301b78cfb8892b84d29302bf25d1283 | MATLAB | 4,893 | 218 | function [xc,good,bad,type] = edgefinder(xt,I,wintx,winty,wx2,wy2);
%[xc] = cornerfinder(xt,I);
%
%Finds the sub-pixel corners on the image I with initial guess xt
%xt and xc are 2xN matrices. The first component is the x coordinate
%(horizontal) and the second component is the y coordinate (vertical)
%
%Based on Har... |
2525414a0e23d5eb06869053cd4074f90dc4d882147895da51865f125d02cb6e | MATLAB | 4,896 | 151 | function [outKer] = nonIsotropicGaussianPSF(inSigma,varargin)
%% NONISOTROPICGAUSSIANPSF - Creates a isotropic / non isotropic 3D Gaussian kernel.
%Uses the Statistical toolbox if installed (mvnpdf). Works without Statistical Toolbox, but slower and
% with higher limitation when it comes to the size of the PSF suppo... |
f26b24d93af0a91ff295a424114086db11d8903c87bbc1026c94728bac62e653 | MATLAB | 4,896 | 170 | function model = treegmFit(X, obs, obsType, weights)
% Fit tree-structured GM using Chow-Liu algorithm.
% INPUT
% X(i,j) is value of case i=1:n, node j=1:d
% X(i,j) should be discrete values, eg {0,1} or {1,2,3}
% The current implementation assumes each node has the same set of values
%
% Optionally we can have ob... |
12c63aa6e41ff8d6bae18647575feafe772fc54f0d1a31fe3d2d12412d279ee1 | MATLAB | 4,897 | 159 | function LAN = lan_add_coord(LAN,real,mni,tal)
% <*LAN)<] toolbox
% v.0.0.3
% Read coordinates for iEEG electrodes
% 02.04.2014 Add option to read from 3 text files (Name, Pos and MNI).
% 14.12.2012
% 03.09.2012
if nargin<4
tal = [];
end
if nargin >3
mni=[];
end
if nargin == 1
realk= [];
[FileName,Pat... |
5ab3704d97759e1353459ba118087017925663ac037fe9c5fd16450c516d57c0 | MATLAB | 4,898 | 118 | function cfg = simpleMAProjectConfigForTesting()
cfg = struct();
cfg.ViewNames = {''};
cfg.LabelPointNames = {'head'; 'tail'; 'rightear'; 'leftear'};
cfg.LabelMode = LabelMode.MULTIANIMAL;
cfg.MultiAnimal = 1;
cfg.Trx.ZoomRadius = 100;
cfg.Trx.ZoomRadiusTight = 10;
cfg.Trx.ZoomFactorDefault = 181.334290... |
d3cae5fb19e2056f07e1bd2ff432395ded7f727d5582bc076802d26bc0c00e34 | MATLAB | 4,898 | 115 | function H = y_QC_Normalization(WorkingDir,SubjectID,IsCheckwT1,IsCheckwFun,IsCheckwGM)
% function H = y_QC_Normalization(WorkingDir,SubjectID)
% Function QC normalization effects.
% Input:
% WorkingDir - The working directory of DPARSF.
% SubjectID - SubjectID need to be QCed.
% IsCheckwT1 - 1 or 0: 1... |
9bbcfadbd4d16fda868f172bb6bca58172bb8c15264ead92d9077e8fdb723111 | MATLAB | 4,900 | 82 | function [EC] = meshneighborints_En(P, t, normals, Area, Center, RnumberE, ineighborE, numThreads)
% Accurate integration for electric field on neighbor facets using the solid angle approach
% Copyright WAW/SNM 2020-2021
ppool = gcp('nocreate');
if isempty(ppool)
tic
parpool(numTh... |
b9d6d55ae0fa4c92ef8e38c1edd712686baa675c6e15c2c72d12fcf22e0c5a6e | MATLAB | 4,901 | 167 | function data = seloverdim(data, seldim, sel, fb)
if nargin<4,
fb = 1;
end
% get all XXXdimord fields
fn = fieldnames(data);
selfn = find(~cellfun('isempty', strfind(fn, 'dimord')));
fn = fn(selfn);
for k = 1:numel(fn)
fndimord{k} = data.(fn{k});
end
% check which XXXdimord fields contain the seldim and ke... |
e090abdd54fc5b4196e0c5e6bf4da8b4bba1cb0f1362b2a769e0fb748cea46a3 | MATLAB | 4,902 | 107 | close all
jheapcl
clear
OS=computer;
if strcmp(OS,'MACI64')
dc='/';
else
dc='\';
end
CurrentDir=cd;
Text2Find='ScaleBar.mat'
LogFileID='Updating Scale Factor For All Post Paper Files'
VariableName2Fix='ScaleBar.ScaleFactor'
Variable2Fix=0.21164; %um per pixel {ENTERPRISE 63x,1.0NA+1.2x Adapter}=0... |
17d750ed3765f8d105f4884ae7d040d34ae7a445cff2b2b682c9cae0427df124 | MATLAB | 4,904 | 133 | function performAffineTransforms_global(fixed_fov, moving_fovmatches, moving_round,bigparams)
filename_root = sprintf('%s-F%.3i',bigparams.EXPERIMENT_NAME,fixed_fov);
image_type = 'ORIGINAL';
ch_list = bigparams.CHANNELS;
image_ext = bigparams.IMAGE_EXT;
outputdir = fullfile(bigparams.EXPERIMENT_FOLDERROOT,...
... |
274ffac08cec60712f2a92aec36e5aecd5cd58578c3c900dfd669f4a7252a920 | MATLAB | 4,904 | 170 | % This demo performs a graphical representation of 2D choice data.
% This script simulates an agent making choices between two options, which
% differ in terms of the expected reward and temporal horizons, under a
% hyperbolic temporal discounting model. It then estimates the 2D utility
% profile, using 2D-Fourier basi... |
9e656311a9a01c38737a01b6286c4c0d94975ace24f076d9bb861753feb0a3cd | MATLAB | 4,904 | 140 | function [ output_args ] = SpecificityAnalysis(TaskLabel,varargin )
%SPECIFICITYANALYSIS Summary of this function goes here
% Detailed explanation goes here
% [varargin,PThresh]=Utilities.ProcVarargin(varargin,'PThresh',.001);
[varargin,saveFig]=Utilities.ProcVarargin(varargin,'saveFig');
[varargin,Labels]=Uti... |
c604f5753c13bea7a71bd18884929eb742ea4abbf8fd775849aff7a1c61626c8 | MATLAB | 4,905 | 153 | clear;
clc;
osc_amp_list = 5:20;
n_iteration = 10;
for snr_iter = 1:length(osc_amp_list)
for iter = 1:n_iteration
fprintf('Iteration #%d\n',iter);
sim_param.srate = 500;
sim_param.osc_amp = osc_amp_list(snr_iter);
sim_param.freq_range = [2 30];
sim_param.noise_amp = 10... |
e3a1944ef5d73bca5241d95571f7abba0e33e61bbdab673a6cde942d5e18cd41 | MATLAB | 4,906 | 213 | clear;
clc;
% close all;
load example_sinusoidal_data_v1.mat
%%
srate = 400;
timex = linspace(-1500,0,srate*1.5);
param.plot = 1;
param.minimum_cycles = 2;
param.ovlp_threshold = 0.50;
param.frequency_axis = 1:40;
[cho_outputs] = CHO_v22(raw_data, srate, param);
%%
[pxx, f] = pwelch(raw_data'... |
0dc91990afb2fdc1398716e316422005a2617697366b4fffc1cb3bffdf90f6db | MATLAB | 4,908 | 171 | % meg_runGroup
% group meg_runAnalysis
% add ft
% addpath '/Users/kantian/Google Drive/Software/fieldtrip-20190416'
% ft_defaults
%% setup
user = 'karen'; % 'mcq','karen','rachel'
expt = 'TANoise'; % ' TANoise' 'TA2'
sessionIdxs = 1:2;
p = meg_params('TANoise_ITPCsession8');
[sessionNames,subjectNames,ITPCsubject... |
41967111970e9f4e3f8fc2bb41034c87c94c4476eabaaedf0cf1d0dac1864863 | MATLAB | 4,908 | 129 | %extracts spikes from raw signal
%applies band-pass filtering to raw signal before doing so.
%
%params.nrNoiseTraces: 0 if no noise should be estimated
% >0 : # of noise traces to be used to estimate autocorr of
% noise, returned in variable autocorr
%
%
%params.detectionMethod: 1 -> from po... |
f735bc73e07c2df51af2f5cbf3f1555338d158b611ac1e93b085dd0146f15735 | MATLAB | 4,909 | 159 | function [haf,hf,hp] = plotUncertainTimeSeries(muX,SX,dTime,hParent,ind,color)
% plots uncertain time series
% function [haf,hf,hp] = plotUncertainTimeSeries(muX,SX,dTime,hParent,ind)
% This function plots uncertain time series, ie time series associated with
% their instantaneous variance.
% IN:
% - muX: a nxT matri... |
0783edd4a3c99427e6796b436dd843855d861186da7226b22c2d907e6e981e21 | MATLAB | 4,910 | 149 | % Train Model, we are not seeking to deal with the features in order to improve the accuracy
%Fine Tree Model
tic;
[Model(1), validationAccuracy(1),validationPred{1}] = FineTree(PredictionTable_2022_Table);
ModelName(1) = "Fine Tree";
modeltime(1)= toc;% Train Model, we are not seeking to deal with the features in... |
749a7ef2d3a3d2cf2867e13f337607c4bb6a6d4be6c0e3db0317eaa29a3e1815 | MATLAB | 4,911 | 99 | function spikeMat = randnet_calculator_memOpt(modelParam, network, simDuration, varargin)
% randnet_calculator_memOpt.m
%
% Simulates network of recurrent LIF neurons. Should produce identical
% spikeMat as randnet_calculator.m but runs slightly faster and with much
% lower memory requirements due to not storing all co... |
f9c2b6c643df344a1296d9c2597f9c16efa9cb0b56bff0eb8ea6aa7c7029f4db | MATLAB | 4,911 | 157 | function [tfr,rtfr,hat] = tfrrpwv(x,t,N,h,trace);
%TFRRPWV Reassigned pseudo Wigner-Ville distribution.
% [TFR,RTFR,HAT] = TFRRPWV(X,T,N,H,TRACE)
% computes the pseudo Wigner-Ville distribution
% and its reassigned version.
%
% X : analysed signal,
% T : the time instant(s) (default : 1:length(X)).
% N ... |
86d93a19cd6cc7b6c17f5dc0fe16f5da865b4af314dd75aa090ee5766b8e444d | MATLAB | 4,912 | 153 | clear;
clc;
osc_amp_list = 5:20;
n_iteration = 10;
for snr_iter = 1:length(osc_amp_list)
for iter = 1:n_iteration
fprintf('Iteration #%d\n',iter);
sim_param.srate = 500;
sim_param.osc_amp = osc_amp_list(snr_iter);
sim_param.freq_range = [2 30];
sim_param.noise_amp = 10... |
9f486f1add3eb037a826cdc6b4a6a7f016374a2080117547e74cc9f890d6b822 | MATLAB | 4,912 | 149 | %% plots the source points for spontaneous, early, and late waves
clear
clc
repTrial =[83 52 42 59 56 60];%48 52 59 56
waveNum{1} = [2];%early wave num to use to T83
waveNum{2} = [2];%early wave num to use to T52
waveNum{3} = [1];%early wave num to use to T42
waveNum{4} = [1];%late wave num to use to T59
w... |
05ce09eeb94d195a56510d0b2a08654b527accde855f4abb5adbbfbdf556c1bd | MATLAB | 4,914 | 113 |
function [TempContrastedImage,TempContrastedImageColor,cMap_Contrasted]=Adjust_Contrast_and_Color_wMask(Temp,TempContrastLow,TempContrastHigh,ColorCode,ColorScalar,MaskIDNum,MaskColor)
WarningStatus=warning;
if isempty(ColorScalar)
ColorScalar=1;
end
if length(MaskIDNum)==1
... |
e700da48302c18d60bcb1bd0e0ec40cd54f380464b3bc04aaaed0ba4409604fa | MATLAB | 4,916 | 97 | clear all
%%
%Define Parameters
[opt] = ParameterOptions();
%%
%Define T2 Array
T2Arr=10:10:300;
%%
%Analytical Solution
for k=1:length(T2Arr)
opt.T2=T2Arr(k);
SAnalytical(k)=FreedDWSSFP(opt.G,opt.tau,opt.TR,opt.alpha,opt.D,opt.T1,opt.T2);
S0Analytical(k)=FreedDWSSFP(opt.G,opt.tau,opt.TR,opt.alpha,0,opt.T1,... |
94a7c9f653477538b84d816446765ba5aa3a9fe2664f6effaa8c51c44ead6e9e | MATLAB | 4,917 | 152 | function [varargout] = ft_plot_box(position, varargin)
% FT_PLOT_BOX plots the outline of a box that is specified by its lower
% left and upper right corner
%
% Use as
% ft_plot_box(position, ...)
% where the position of the box is specified as is [x1, x2, y1, y2].
%
% Optional arguments should come in key-value pai... |
6c03b36b9359f34d703bd265e509997c2a79aca4bb98cb5ca6957d61a6176bf6 | MATLAB | 4,918 | 134 | function varargout = IsAnatOnly(varargin)
% ISANATONLY MATLAB code for IsAnatOnly.fig
% ISANATONLY, by itself, creates a new ISANATONLY or raises the existing
% singleton*.
%
% H = ISANATONLY returns the handle to a new ISANATONLY or the handle to
% the existing singleton*.
%
% ISANATONLY('CALL... |
8b03c282208436925d710e16479dc43ebbfc3383d6311b9f05022c184ec7c5ef | MATLAB | 4,918 | 176 | function [t,amps,data,aux] = read_intan_data(channels, filename)
% [t,amps,data,aux] = read_intan_data
%
% Opens file selection GUI to select and then read data from an Intan
% amplifier data file (*.int).
%
% t = time vector (in seconds)
% amps = vector listing active amplifier channels
% data = matrix of e... |
50f29d732de17906e2cfa06cfa4a3f864fac596ee628f2ec12747a957e3468d7 | MATLAB | 4,919 | 153 | function A = catstruct(varargin)
% CATSTRUCT Concatenate or merge structures with different fieldnames
% X = CATSTRUCT(S1,S2,S3,...) merges the structures S1, S2, S3 ...
% into one new structure X. X contains all fields present in the various
% structures. An example:
%
% A.name = 'Me' ;
% B.income = 99... |
3a73d3aea551e9c61ea068153a050be9a1b3129b64ec037c68e341feb8bbc8de | MATLAB | 4,921 | 167 |
for sess = 1 : 8
disp([dNames{d} ', Session ' num2str(sess)])
clear w
ff = fullfile(saveLoc,...
[dNames{d} '_w_S' num2str(sess)]);
load(ff, 'w')
if size(w, 1) > size(w, 2); w = w'; end
% Take out Min neurons
mins = [par_sess{sess}.unit_MinC par_sess{sess}.unit_M... |
921ab9507b0ad3d816bcbdd40173011fab1287c3925000db5a32eac7782dab2b | MATLAB | 4,921 | 125 | % missing_eye_data.m
% Sarah West
% 6/17/22
% A script that finds stacks that don't have eye data & creates vectors of
% NaN for the pupil diameters. Checks with the not-yet normalized pupil
% diameters, saves with the normalized pupil diameters (so the results
% don't change each time you run it).
%% Initial setup
%... |
6d9f47ce10530d4932fadce9187ecdc625a1476b26e0d52df122b19cecb74e20 | MATLAB | 4,922 | 120 | %% WRAPPER for analyzing multi-ExR cultured neurons %%
% Accompanies the manuscript by Kang*, Schroeder* et al., 2023
% Last modified by Margaret Schroeder on 3/13/23
% Image processing up to this point:
% - background subtraction in Fiji and
% - registration using modified ExSeq pipeline
% NOTE: It's best to run ... |
b6c0f08c14062cca3d3d93ffdf3cef97278367cf3a389fea79a52a66f80a4e6a | MATLAB | 4,925 | 170 | function [FC_simR, CC_check] = CBIG_MFMem_rfMRI_nsolver_eul_sto(parameter,prior,SC,y_FC,FC_mask,Nstate,Tepochlong,TBOLD,ifRepara)
%-----------------------------------------------------------------------------
% FC_simR, CC_check] = CBIG_MFMem_rfMRI_nsolver_eul_sto(parameter,prior,SC,y_FC,FC_mask,Nstate,Tepochlong,TBOL... |
5a1dd629ec0c1090b7477741f9dcaa68731290a986052eb0e733289f4d99909b | MATLAB | 4,926 | 149 | classdef NameColoringDlg <handle
properties(SetAccess=private)
table; %SortTable
t;
jt;
updating=false;
colors;
changed;
names;
N;
app;
end
methods
function this=NameColoringDlg(names, colors, itemName, fncRefresh)
... |
8a317abdba9c36384eda91c01780944b63dc5d252dec3910f664c289a173f95a | MATLAB | 4,926 | 193 | function [pnt, tri] = mesh_spherify(pnt, tri, varargin)
% Takes a cortical mesh and scales it so that it fits into a
% unit sphere.
%
% This function determines the points of the original mesh that support a
% convex hull and determines the radius of those points. Subsequently the
% radius of the support points is int... |
c7952103ca37ad365f5233a70f123a45766607865acd87e05995bdecaa156e87 | MATLAB | 4,927 | 125 | function [out] = DFTFsj_getriptimes(animaldir,animalprefix, epochs, varargin)
% out = getriptimes(animaldir,animalprefix,epochs, tetlist, options)
%
% animaldir and animal prefix are strings indicating the base director for
% the animal's data and the prefix for the data files
%
% epochs is an Nx2 list of d... |
c7cc2d7af59b0953ff738d32cd192c40a15eebda09a9fad23fefc34f02b02b19 | MATLAB | 4,927 | 157 | function h_dragTracingMark3
[currentInd, handles, currentStruct, currentStructName] = h_getCurrendInd3;
state = currentStruct.state;
data = currentStruct.image.data;
% point1 = get(gca,'CurrentPoint'); % button down detected
% point1 = point1(1,1:2); % extract x and y
tracingMarkObj = findobj... |
e71a653410565677f09af39cee9187065e0b7385c52538ef77a2d848dcb95b89 | MATLAB | 4,927 | 130 | function oimg = loadtiff(path)
% Copyright (c) 2012, YoonOh Tak
% All rights reserved.
%
% Redistribution and use in source and binary forms, with or without
% modification, are permitted provided that the following conditions are
% met:
%
% * Redistributions of source code must retain the above copyright
% ... |
699f0403403bc956f21247978c599d5272f9ba134ee59c7d47e9f334e80d7e66 | MATLAB | 4,932 | 144 | %%
% 5th Variant of the compute SDO Matrix algorithm
% NOTE: The assymmetrization of the net matrix DOES NOT give the same
% matrix as the sum of assymmetrized matrices;
% To 'asymmetrize' the matrix, we find the 'symmetrical' component around the matrix diagonal,
% which is the elementwise minimum between M(i,j) &... |
1cccbdc583b6f32889c11808a04ae0f4654f16ee66f4a6f48526b18bebd93d4a | MATLAB | 4,936 | 157 | %REAL2RGB Converts a real-valued matrix into a truecolor image
%
% Examples:
% B = real2rgb(A, cmap);
% B = real2rgb(A, cmap, lims);
% [B lims map] = real2rgb(...);
%
% This function converts a real-valued matrix into a truecolor image (i.e.
% double array with values between 0 and 1) using the colormap specifie... |
e1a5905596f8c3f2c48c8e472119419ee9c3a51aa6d050cd8c8a079c9004e32f | MATLAB | 4,938 | 157 | clear;
clc;
% osc_amp_list = 20;
osc_amp_list = [5:20];
n_methods = 4;
n_iteration = 30;
%
for snr_iter = 1:length(osc_amp_list)
for iter = 1:n_iteration
fprintf('Iteration #%d\n',iter);
sim_param.srate = 500;
sim_param.osc_amp = osc_amp_list(snr_iter);
sim_param.freq_range = ... |
422fe7efede8c8f63ec790f27736b1e0c2d1ca1d7bd0459f1a35b785b61b865e | MATLAB | 4,942 | 194 | function t3 = merge_table(t1, t2, key)
% MERGE_TABLE merges two tables where the rows and columns can be partially
% overlapping or different. Values from the 2nd input have precedence in case the
% same row and column is also present in the 1st.
%
% Use as
% t3 = merge_table(t1, t2)
% or
% t3 = merge_table(t1, t2... |
40c641a5d215da48c5e277b116af63d77e312b2770e36d0d3544b3c546173380 | MATLAB | 4,943 | 170 | function [FC_simR, CC_check] = CBIG_MFMem_rfMRI_nsolver_eul_sto_4p(parameter,prior,SC,y_FC,FC_mask,Nstate,Tepochlong,TBOLD,ifRepara)
%-----------------------------------------------------------------------------
% FC_simR, CC_check] = CBIG_mfm_rfMRI_nsolver_eul_sto(parameter,prior,SC,y_FC,FC_mask,Nstate,Tepochlong,TBO... |
593640837a43f8d04e43fe010fb6197853a8bdad3121b55232d2803802919d3f | MATLAB | 4,943 | 142 | function [F1490,F1405]=Manual_Removal_Artifacts(t,Sig_2,Sig_3,smth,dir_r,um_a)
F1490=Sig_2;%smooth(Sig_2, smth,'loess');
F1405=Sig_3;%smooth(Sig_3, smth,'loess');
%F490mean= movmean(Sig_2,5000);
%F405mean= movmean(Sig_3,5000);
Diff_2= diff(F1490)' ;
Diff_3= diff(F1405)' ;
... |
5a9e7522f3cdc16f47d27600ee414830afd9b24729babe862e2b85e459502267 | MATLAB | 4,945 | 157 | clear;
clc;
% osc_amp_list = 20;
osc_amp_list = [5:20];
n_methods = 4;
n_iteration = 30;
%
for snr_iter = 1:length(osc_amp_list)
for iter = 1:n_iteration
fprintf('Iteration #%d\n',iter);
sim_param.srate = 500;
sim_param.osc_amp = osc_amp_list(snr_iter);
sim_param.freq_range = ... |
a2b677325ea3da4312adc57e79c1f1e7bd5c39e9d79b5629d7085773c33fc1e4 | MATLAB | 4,945 | 163 | function CPD = condStudentCpdCreate(mu, Sigma, dof, varargin)
%% Create a conditional student distribution for use in a graphical model
%
% Adapted from code written by Robert Tseng
%%
% This file is from pmtk3.googlecode.com
[prior, estimateDof] = process_options(varargin, 'prior' , [], 'estimateDof', true); % pri... |
170294811608609f8d3f2ae5b763ede523b13e94f974385f6c226589a1dfa59d | MATLAB | 4,948 | 132 | function CBIG_KRDNN_KRR_HCP(CBIG_CODE_DIR, subject_list, unrestricted_csv, restricted_csv, FD_file, FC_file, output_dir)
% CBIG_KRDNN_KRR_HCP(CBIG_CODE_DIR, subject_list, unrestricted_csv, restricted_csv, FD_file, FC_file, output_dir)
%
% This function runs the kernel ridge regression algorithm to predict
% behaviora... |
219e75235edd4f6de9c69fa46d0874342880dfc734e33e03c4409f237ed2bbf4 | MATLAB | 4,948 | 91 | %-----------------------------------------------------------------------------------------
% Plot Venn diagram of odor and image modulated neurons
%
% Kehl et al. 2024 (DOI:XX)
% Single-Neuron Representations of Odors in the Human Brain
% Figure 5c
% Author: Marcel Kehl
% License: MIT License
%----------------------... |
2c1c7c3df229b7adedfcb6a3c688274947052b90fc15ff7d9cb2382628a601fc | MATLAB | 4,949 | 140 |
% Load data
load(fullfile(saveLoc, 'cosine_sim'), 'cosine_sim')
load(fullfile(saveLoc, 'resCorr_wiTrial'), 'all_zrMean');
load(fullfile(saveLoc, 'cosine_sim_randperm'), 'cosine_sim_randperm') % cosine_sim_randperm(sess, d1, d2, :)
%load(fullfile(saveLoc, 'resCorr_wiTrial_rand_gauss'), 'par_sess', 'filtW50b', 'r... |
111a0eabe92e71cb0bc1a657f02e5506c15f4c8b8c171c81237c5aacbf5419c7 | MATLAB | 4,951 | 191 | %mmf writer
function [keyframes,nframes]=mmfwriter2(inputfile,outputfile,obj,firstframe,lastframe)
%obj=VideoReader(inputfile);
foutput=fopen(outputfile,'wb');
%load text
ftexto=fopen('/groups/visitors/home/albam/Desktop/mmfreader/text.text');
texto=[];
for i=1:15
linea=fgets(ftexto);
texto=[texto linea];
end
%write... |
b4bf69386bc53da25cd0250a019d2dd7519729f62d928977c9d9a867f7e730a9 | MATLAB | 4,952 | 133 | function [s, cfg] = ft_statfun_indepsamplesregrT(cfg, dat, design)
% FT_STATFUN_INDEPSAMPLESREGRT calculates independent samples regression coefficient
% T-statistics on the biological data in dat (the dependent variable), using the
% information on the independent variable (predictor) in design.
%
% Use this function... |
2fe4d581772ccf3ce1bdbe96824d7e9e60ca3fac0026d6ebb78d6c2bac829e46 | MATLAB | 4,954 | 124 | function afxPreprocHCP(options,cond,sampleName,subjectName,info,fix)
if nargin < 5, info = struct([]); end
if nargin < 6, fix = false; end
outDir = fullfile(pwd,'data',sampleName,'subjects',subjectName);
if fix
movefile(outDir,strcat(outDir,'_broken'))
else
if exist(fu... |
2eccda1ec5d1869f530d52d7ff167b9802c013c474cfa1db3f561290b5f4c85b | MATLAB | 4,955 | 155 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%Bins F data by velocity.
%Chad Heer
%INPUTS
%data = struct with Fc data from axon analysis
%beh = struct with all behavioral variables
%trackLength = length of track
%frames = matrix with frame numbers for each task
%tasks = task ids
%OUTPUTS
%data = data struct with appended bin... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.