sha256 stringlengths 64 64 | language stringclasses 27
values | size int32 1 491k | lines int32 1 21.8k | content stringlengths 1 200k |
|---|---|---|---|---|
297aaa13e41d7b066ad5cd65a137bcfec75fbe34277641793f2d2b2f9680681c | MATLAB | 29,680 | 718 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% 09/12/2019
% The code is designed to conduct a series of analysis on the output of the
% Brownian Dynamcis code with Immune Response
% It is based on the main time-sample based code of the original BD
% simulation, but designed to run wi... |
e524193eab675d38c2921218a8eb3c383bf92fa92bcbf38f4042cf106ad09738 | MATLAB | 29,805 | 847 | %%%% EXTERNAL FUNCTION
% function taken from the BioSig package
% complete software may be downloaded from http://biosig.sourceforge.net/
function [ARF,RCF,PE,DC,varargout] = mvar(Y, Pmax, Mode);
% MVAR estimates Multi-Variate AutoRegressive model parameters
% Several estimation algorithms are implemented, all estimat... |
8e4f8670c134a8cf5d5794e9b40a39ac40abf43cd8531187cf68196e4f62e28d | MATLAB | 29,979 | 767 | % Requires raw session data (not in repo).
% Internal paths must be configured manually for your local environment.
addpath(genpath('S:/Roy/ryhattori-PatchWarp-1.3.3.0'));
% calculate trace means and stds
% TODO - report baseline trace means over each session, i.e. see if there is a drifting baseline in each session ... |
85256b5fc3baa6a5c55cfd1b2bfbcc33711333ce7dcd50798378520d85178ac1 | MATLAB | 30,151 | 699 | %% Plot RFR contrast maps
%created on 2025/08/22
clear global; clc; clear; close all;
addpath('/kyb/agks/mcapiglioni/Documents/MATLAB/OLD_matlab//PostProcessing/NEMO_pipeline/')
addpath('/kyb/agks/mcapiglioni/Documents/MATLAB/OLD_matlab/Include_files/')
% data_path = '/str/data/Analysis/Trento/Analysis_paper/MR_mea... |
0e179e69a63768e1a37a419d2a7ccb0a638794a558ba701d4b51cb8751ecbe5f | MATLAB | 30,211 | 770 | %--------------------------------------------------------------------------
% Till Habersetzer, 15.07.2025
% Communication Acoustics, CvO University Oldenburg
% till.habersetzer@uol.de
%
% Description:
% Analyzes and visualizes neural decoding results. This script evaluates
% model performance on held-out test dat... |
c533936f975f10bc3aa2a7c9d5174ea9a60073e594bc25d2095d0c51e9a3ffd3 | MATLAB | 30,402 | 637 | % current working directory needs to be /path/to/scripts
mainpath= pwd;
addpath([mainpath filesep 'toolboxes' filesep 'tc_functions'])
addpath([mainpath filesep 'fmriRegAnalysis'])
addpath([mainpath filesep 'toolboxes' filesep 'fieldtrip'])
addpath([mainpath filesep 'toolboxes' filesep 'OpenFmriAnalysis'])
tvm_install... |
10bf3c050a1ff0b4803f59b3a93be7cefa1deb5206859af572570cbe69d62bbc | MATLAB | 30,827 | 764 | function varargout = nst_ppl_1st_level_channel_V1(action, options, arg1, arg2)
%NST_PPL_1ST_LEVEL_CHANNEL_V1
% Run a full channel-space intra-subject pipeline
% starting from raw NIRS data up to GLM contrasts (effect and t-stat maps).
%
% DEFAULT_OPTIONS = NST_PPL_1ST_LEVEL_CHANNEL_V1('setup', PROTOCOL_NAME)
% ... |
df3f84a007c555597d04dc19a27578479c6bb2e319f6ebc48386145f01c6a860 | MATLAB | 30,977 | 534 | function [ idk3, kkk2, KJK ] = FunctionalSpatialClustering_voxels2ROIs_LBPD_D( S )
% It computes kmeans clustering to define a functionally-based
% parcellation. It usually reduces 3559 voxels into a set of approximately
% 10-30 parcels.
% The algorithm works combining the temporal and spatial profiles of each
% voxel... |
7db03770affa00dfb9d59f7d89bafec03c22844ea11d23e456769ec2c35377a3 | MATLAB | 31,117 | 605 | function print2eps(name, fig, export_options, varargin)
%PRINT2EPS Prints figures to eps with improved line styles
%
% Examples:
% print2eps filename
% print2eps(filename, fig_handle)
% print2eps(filename, fig_handle, export_options)
% print2eps(filename, fig_handle, export_options, print_options)
%
%... |
206026f9cd7510fbe5b108e31fb73a74c44b3112017b3aba38254884b899f010 | MATLAB | 31,605 | 551 | function [b2b,k_info,Ind1,Ind2,Ind3] = islands3D_LBPD_D(a,infor)
% It finds all islands in a 3D binary matrix.
% An island is here defined as a cluster of same neighbouring values along the 3 dimensions.
% A single element is not considered a cluster.
% The function works ignoring NaN if any.
% INPUT: -a... |
25a34f6a0a7f7aa8cb8e65d83bc58652c4fafe5bfbd03f1ae1d57ce6f70aaebd | MATLAB | 32,320 | 924 | 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... |
76ec667cabd53f0ee77053503b0d527de74676cd14b06e3d43374514d341a48c | MATLAB | 33,194 | 1,095 | function H = hatchfill2(A,varargin)
% HATCHFILL2 Hatching and speckling of patch objects
% HATCHFILL2(A) fills the patch(es) with handle(s) A. A can be a vector
% of handles or a single handle. If A is a vector, then all objects of A
% should be part of the same group for predictable results. The hatch
% consis... |
f5721041f3b767fd8d57927e5eaabf56bb4fa4423ebb41284a932437798cf655 | MATLAB | 33,284 | 531 | %%
% current working directory needs to be /path/to/scripts
mainpath=pwd;
addpath([mainpath filesep 'toolboxes' filesep 'tc_functions'])
addpath([mainpath filesep 'toolboxes' filesep 'fieldtrip'])
addpath([mainpath filesep 'fmriRegAnalysis'])
ft_defaults
%%
freqs = {'alpha', 'gamma'};
hemis = {'lh', 'rh'};
blocks = 1:... |
7ee34c76289c59a06a2ff710c495941c5cb0fe1c0bb8bf7e3f6dc66e878e2ac8 | MATLAB | 33,963 | 723 | classdef MatrixPlot < handle
%MATRIXPLOT Base class for drawing a matrix or tri-matrix organized by
% networks.
%
% plot_object = MatrixPlot(figure, name, matrix_data, networks, figure_size, OPTIONS)
% Options should be written as parameter-value pairs.
% i.e. (...,"marked_networks", true, "low... |
c5a71bdf8e00218f458aade84cb6e987ce3a971d89ed05b049cc8f7a9cc88789 | MATLAB | 35,076 | 699 | function [] = plot_sensors_wavebis2(S)
%%% TO BE CHECKED AND SISTEMATA!!
%% Plot waveforms at sensors
% Plot waveform at MEG sensors (magnetometers or gradiometers) of interest. The
% signal can be plotted for single conditions (to be specified) or as the average across the selected conditions.
% Wavef... |
40405f1fda3382cd0dd680a0f3a1627c1a5ce608936db4f0e543ee0e0139fe66 | MATLAB | 35,856 | 883 | function cfg = topoplot_common(cfg, varargin)
% TOPOPLOT_COMMON is shared by FT_TOPOPLOTTFR, FT_TOPOPLOTER and FT_TOPOPLOTIC, which
% serve as placeholder for the documentation and for the pre/postamble.
% Copyright (C) 2005-2011, F.C. Donders Centre
%
% This file is part of FieldTrip, see http://www.fieldtriptoolbox... |
bacec17b2f8d961e0912c59cfc4e8928e5ec5ff19f5e4e7ff343dbe3bb08fe11 | MATLAB | 36,958 | 838 | function varargout = NOW_GUI(varargin)
% NOW_GUI MATLAB code for NOW_GUI.fig
% NOW_GUI, by itself, creates a new NOW_GUI or raises the existing
% singleton*.
%
% H = NOW_GUI returns the handle to a new NOW_GUI or the handle to
% the existing singleton*.
%
% NOW_GUI('CALLBACK',hObject,eventData,... |
66bb92aa7b76cace7cae919cd70f11d2fd58dc680c156d5ffb05d2748fc12665 | MATLAB | 37,279 | 726 | classdef NetworkTestPlotApp < matlab.apps.AppBase
% Properties that correspond to app components
properties (Access = public)
UIFigure matlab.ui.Figure
Menu matlab.ui.container.Menu
SaveasMenu matlab.ui.container.Men... |
9810215653d1d1783f55283b79a0c2baa6d6a94f278e2254ce13136daf543d16 | MATLAB | 37,680 | 916 | %% Plot RFR contrast maps
%created on 2025/08/22
% clear global; clc; clear; close all;
addpath('/home/user/matlab/PostProcessing/NEMO_pipeline/')
addpath('/home/user/matlab/Include_files/')
% set plot parameters
show = 1;
save_figure = 1;
stim_sides = [1 2];
slices = [1 2 3];
% stimulation parameters
stim.number_b... |
2a1e8521c91de3f8502b103d6aadc1f7b648ba9893304c03dcc6a8362107bd1a | MATLAB | 37,728 | 1,084 | function varargout = conduction(varargin)
% Function for running conduction GUI.
% Chris O'Shea and Ting Yue Yu, University of Birmingham
% Maintained by Chris O'Shea - Email CXO531@bham.ac.uk for any queries
% Release Date -
% For licence information, please see 'licsence.txt' at ...
% Last Updated -
% Update S... |
ee26236b12d18555133e17ad06b5b468bd8f08f2381edeaa15ec338f7001a769 | MATLAB | 37,940 | 944 | function varargout = nst_ppl_surface_V1(action, options, arg1, arg2)
%NST_PPL_SURFACE_TEMPLATE_V1
% Manage a full template- and surface-based pipeline starting from raw NIRS data
% up to GLM group analysis (if enough subjects).
%
% IMPORTANT: although each subject has its own optode coordinate file during importation,
... |
a5b52aafe29e308a34f0def25e918eafbd09007085395c84dddcb9f5a3ce3263 | MATLAB | 39,513 | 767 | function [ OUT ] = MEG_sensors_plotting_ttest_LBPD_D_marina( S )
% It prepares data (loading data or extracting it from SPM objects (usually
% obtained from previous preprocessing in OSL)), optionally calculates t-tests
% between two conditions and then provides multiple plotting options:
% 1)single-channel waveforms
... |
b29bafa6bdc9810a27a49b73cc59d558ee3a2822a28633698d4ba315a7736a30 | MATLAB | 41,060 | 912 | classdef NLAResult < matlab.apps.AppBase
% Properties that correspond to app components
properties (Access = public)
UIFigure matlab.ui.Figure
FileMenu matlab.ui.container.Menu
SaveButton matlab.ui.container.Menu
Sa... |
d426b33f672f2c1d2f314afcfe3d8d0539c32986603ce6ba8288851bdef11d22 | MATLAB | 43,820 | 839 | function [ OUT ] = MEG_sensors_plotting_ttest_LBPD_D( S )
% It prepares data (loading data or extracting it from SPM objects (usually
% obtained from previous preprocessing in OSL)), optionally calculates t-tests
% between two conditions and then provides multiple plotting options:
% 1)single-channel waveforms
% 2)ave... |
8a27527833d6369cbb8b5f8115147137c2c5c52a1d8846942801d4cc7e9e8d67 | MATLAB | 45,109 | 1,208 | close all
clear
% current working directory needs to be /path/to/scripts
mainpath = pwd;
cd(mainpath)
addpath([mainpath filesep 'toolboxes' filesep 'tc_functions'])
addpath([mainpath filesep 'toolboxes' filesep 'fieldtrip'])
addpath([mainpath filesep 'fmriRegAnalysis'])
addpath([mainpath filesep 'scriptTemplates'])
ft... |
9cd621cfc0ce294f5847bb9f77035fd1072a0f82f65cef378950a07a716db7a1 | MATLAB | 45,397 | 721 | function h = copyUIAxes(varargin)
% use COPYUIAXES to copy the content of a UI axis to a new figure.
% COPYUIAXES receives the handle to a UI axes and copies all of its
% children and most of its properties to a new axis. If the UI axis
% has a legend, the legend is copied too (but see tech notes below).
% The ha... |
bb0859afac0405a174c5612b81dd93d0a71292b15734fafc85a8eaf09e3338ab | MATLAB | 45,882 | 1,397 | %% Overview
% The main goal of this pipeline is to assess whether the proposed
% CFA-correction method using CDM-estmate requires a toros model
% including the head.
% The script also contains code to reproduce the corresponding figures in
% the manuscript.
%% Set up environment and load required packages
clearvars
... |
0cf1f93829c0b5796e03f84a2aac1565ce544d98adcf74c37537e8cb02986d5d | MATLAB | 47,239 | 1,122 | function [] = NeuroAnalysis_BehavioralParametricSweepPlanarV2(sourceFolders)
% Program which processes the data aquired during behavioral paired imaging
% and stimulation experiments.
warning('off','all')
warning('off','MATLAB:MKDIR:DirectoryExists');
elecPos = zeros(32,1); % Possible electrode ... |
59febce1f6582df59111b1a205aa673a78ad39c31ea658068436c077af173fbc | MATLAB | 48,462 | 920 | function [ OUT ] = MEG_sensors_plotting_ttest_LBPD_D2( S )
% It prepares data (loading data or extracting it from SPM objects (usually
% obtained from previous preprocessing in OSL)), optionally calculates t-tests
% between two conditions and then provides multiple plotting options:
% 1)single-channel waveforms
% 2)av... |
b2dd48cb2b3931a9d4e417f5299fa3212680ff0679718b0f75e44a2f78c78813 | MATLAB | 48,743 | 778 | function colocalization_module_New()
% Use data and listbox as global variables (access from anywhere).
global data listbox
% Make a new figure, and set its properties.
figure();
set(gcf,'name','Colocalization Module','NumberTitle','off','color','k','units','normalized','position',[0.25 0.2 0.5 0.6],'menubar',... |
7b7cda71782fda00723b6eb984d4299209b586e7ee84db58ed2437bdb4149873 | MATLAB | 48,812 | 1,327 | %%
%% Step 1: Merge all subject results into one large file
%% Final dimension: ICPCall_all(sub, condi, seed, chan, freq, time)
%% Merge all subject ISPC results
clc; clear; close all;
% === 1️⃣ Set path ===
baseDir = 'F:\PIT\correct_all\HC';
cd(baseDir);
fileList = dir('*_ISPC.mat');
nSub = numel(fileList);
fprintf(... |
f6bc9d2edb03667dce752073a01a0789c0f81024510fa0a8a72335ee1d604003 | MATLAB | 50,331 | 1,234 | %% make cluster stats
% Current working directory must be set to /path/to/scripts
mainpath=pwd;
addpath([mainpath filesep 'toolboxes' filesep 'tc_functions'])
addpath([mainpath filesep 'toolboxes' filesep 'fieldtrip'])
addpath([mainpath filesep 'fmriRegAnalysis'])
addpath([mainpath filesep 'scriptTemplates'])
addpath([... |
dd64615f1841121907e9a6e0b2772a12e2bcad9dff4a30b2feb4d96b528175e9 | MATLAB | 52,086 | 1,323 | function varargout = process_nst_OM( varargin )
% @=============================================================================
% This software is part of the Brainstorm software:
% http://neuroimage.usc.edu/brainstorm
%
% Copyright (c)2000-2013 Brainstorm by the University of Southern California
% This software is d... |
f9b89cd68eac1d0c7d24165fdeffb9872183d56c9f4e8432ad3fcb852e7b885e | MATLAB | 52,725 | 1,372 | clear variables
addpath(genpath('/Volumes/Samsung_T5/Milan_DA/OS_ephys_da/CorticoHippocampal'))
addpath('/Volumes/Samsung_T5/Milan_DA/RGS14_Ephys_da')
addpath ('/Volumes/Samsung_T5/Milan_DA/OS_ephys_da/ADRITOOLS')
addpath(genpath('/Volumes/Samsung_T5/Milan_DA/OS_ephys_da/FMAToolbox'))
cd('/Volumes/Samsung_T5/Milan_DA/... |
d08d7601a473e796a9d368205747712762fb46010017ffff1a1495f947484ea7 | MATLAB | 53,630 | 1,533 |
%% Data organization
clc;
clear;
% Set data folder paths
golefttowin = 'F:\PIT\correct_all\TF\GLW\OCD';
golefttoavoid = 'F:\PIT\correct_all\TF\GLA\OCD';
nogotowin = 'F:\PIT\correct_all\TF\NGW\OCD';
gorighttowin = 'F:\PIT\correct_all\TF\GRW\OCD';
gorighttoavoid = 'F:\PIT\correct_all\TF\GRA\OCD';
nogotoavoid = 'F:\PIT\... |
7d7c6f83bd7e8d980654a7066e0aedc0ef9b8e005a036f545758d61f627687f2 | MATLAB | 53,936 | 910 | function [ OUT ] = MEG_SR_Beam_LBPD( S )
% Function to run the several steps required for source reconstruction
% using a beamforming algorithm.
% The algorithms used here are based on work of other brilliant people and
% I do not want to take any credit for that. This function was created simply
% to handle several s... |
b6978e40387b593c6a4d29c4412b02488e57f3acbede940c31051b186d6ebf5d | MATLAB | 55,361 | 1,295 | %% Experiment - Class for loading and processing experimental data
%
% This class handles loading, processing, and organizing experimental data
% from CSV and JSON files, including conditions, raw data, targets, obstacles,
% task settings, and fixation points. It supports data segmentation, metadata
% building, an... |
857f20748641b709c491b069e3f319aa697629b9126c4f1d3cf3464036cc55eb | MATLAB | 57,208 | 1,328 | % Reads and writes Insight3 molecule lists
%
% Read a molecule list
% i3 = Insight3('D:/sample.bin');
% % to access the data in the molecule list you can use the following in your program
% i3.data;
% % or you can create a copy of the molecule list and use this new variable
% mList = i3.getData();
%
% Create a... |
4501c14ff33600c47ba5d6cb3d2c7ad450576e0c0033da51b102137daa109bee | MATLAB | 57,618 | 1,410 | function varargout = alternangui(varargin)
% Function for running Alternan GUI
% Chris O'Shea and Ting Yue Yu, University of Birmingham
% Maintained by Chris O'Shea - Email CXO531@bham.ac.uk for any queries
% Release Date -
% For licence information, please see 'licsence.txt' at ...
% Last Updated -
% Update Sum... |
5e8ec01398dbe3c07c13fbdf100ab91fda1e57f8e222e67ac2807b33a2a857b7 | MATLAB | 57,623 | 1,410 | function varargout = alternangui(varargin)
% Function for running Alternan GUI
% Chris O'Shea and Ting Yue Yu, University of Birmingham
% Maintained by Chris O'Shea - Email CXO531@bham.ac.uk for any queries
% Release Date -
% For licence information, please see 'licsence.txt' at ...
% Last Updated -
% Update Sum... |
fa11904d4735380aa0e97dc8edfb3811b1c9792618ebd12266a4be0813f5d742 | MATLAB | 58,430 | 1,284 | function varargout = nst_ppl_surface_template_V1(action, options, arg1, arg2)
%NST_PPL_SURFACE_TEMPLATE_V1
% Manage a full template- and surface-based pipeline starting from raw NIRS data
% up to GLM group analysis (if enough subjects).
%
% IMPORTANT: although each subject can have its own optode coordinate file during... |
fed43ef5a4f8c037f0c560a5ab70a42d8fc6bd8cacefc3f8eff1cee70b2eb133 | MATLAB | 61,885 | 1,686 | function varargout = segEP(varargin)
% Main function for running single file analysis GUI.
% Chris O'Shea and Ting Yue Yu, University of Birmingham
% Maintained by Chris O'Shea - Email CXO531@bham.ac.uk for any queries
% Release Date -
% For licence information, Please see 'licsence.txt' at ...
% Last Updated -
... |
7979ebd6e438ad9e5ba8a84e945c6cf400b71e06975972e9981476daadab8fc2 | MATLAB | 61,893 | 1,686 | function varargout = segEP(varargin)
% Main function for running single file analysis GUI.
% Chris O'Shea and Ting Yue Yu, University of Birmingham
% Maintained by Chris O'Shea - Email CXO531@bham.ac.uk for any queries
% Release Date -
% For licence information, Please see 'licsence.txt' at ...
% Last Updated -
... |
d6fafdda7f3147b8015baa5ca9f7b6486fb88d2ffc6bd621a331ea1f1202e6b4 | MATLAB | 65,438 | 1,236 | %%
%% NOTES FOR FUTURE CHIARA
% this code include all the steps, from preprocessing to GED. You didn't
% actually perform all these steps, you did everything starting from
% epoching. Most of these steps need to be repeated for memory and
% resting, some of the are different among the two conditions (for example epoch... |
dfd0698edfb0fc7a9c9fde771959fba39034f109bd5d7ed015dca0ad9a2ed12b | MATLAB | 72,583 | 1,891 | % <strong>TIFFStack</strong> - Manipulate a TIFF file like a tensor
%
% Usage: tsStack = <<strong>TIFFStack</strong>(strFilename <, bInvert, vnInterleavedFrameDims>)
%
% A TIFFStack object behaves like a read-only memory mapped TIFF file. The
% entire image stack is treated as a matlab tensor. Each frame of the fil... |
b13b273cbe2503ebab0c0fdf997e79a3f568fcb0ee62bf3b1281dc3779618fec | MATLAB | 74,311 | 1,520 | function [imageData, alpha] = export_fig(varargin) %#ok<*STRCL1>
%EXPORT_FIG Exports figures in a publication-quality format
%
% Examples:
% imageData = export_fig
% [imageData, alpha] = export_fig
% export_fig filename
% export_fig filename -format1 -format2
% export_fig ... -nocrop
% export_fig ... |
d49246d7c72f7538fc4fc492836ed10542e48a7fc27e333a4147d70c051d7e58 | MATLAB | 76,072 | 1,717 | function BCCT_ShowWTAGUI
has.fig = figure('units','norm','pos',[0.3 0.4 0.4 0.2]);
has.infocol = uicontrol('parent',has.fig,'units','norm','pos',[0.2 0.7 0.2 0.2],'style','pushbutton','string','Collect Information');
has.infocoled = uicontrol('parent',has.fig,'units','norm','pos',[0.4 0.7 0.4 0.2],'style','text','st... |
5b9ec893bc794c31688f612dfdf9ed23fc378efd898d78eb80f48c1b20648685 | MATLAB | 76,521 | 1,771 | function AS_ShowGCGUI
[pat nam ext] = fileparts(which('AS_ShowFCGUI.m'));
templatepath = fullfile(pat,'mni_icbm152_t1_tal_nlin_asym_09a.nii');
Hsize = get(0,'screensize');
MIDPOINT = [Hsize(3)/2,Hsize(4)/2];
Asize = [100*3,100+40];
MaxSIZE = [Hsize(3) Hsize(4)]*0.8;
factor = MaxSIZE./Asize;
factornew = min(fact... |
61880d65135ed08f36185dba5a03cebef1b28afacc28a66e86fe69864f62a393 | MATLAB | 76,525 | 1,771 | function AS_ShowGCGUI_res
[pat nam ext] = fileparts(which('AS_ShowFCGUI.m'));
templatepath = fullfile(pat,'mni_icbm152_t1_tal_nlin_asym_09a.nii');
Hsize = get(0,'screensize');
MIDPOINT = [Hsize(3)/2,Hsize(4)/2];
Asize = [100*3,100+40];
MaxSIZE = [Hsize(3) Hsize(4)]*0.8;
factor = MaxSIZE./Asize;
factornew = min(... |
c84366aa15ab26b2f7942e964978cc7631307176e9ef2ad7931fb08d2c3e395c | MATLAB | 82,173 | 1,883 | function AS_ShowGCGUI_coef
[pat nam ext] = fileparts(which('AS_ShowFCGUI.m'));
templatepath = fullfile(pat,'mni_icbm152_t1_tal_nlin_asym_09a.nii');
Hsize = get(0,'screensize');
MIDPOINT = [Hsize(3)/2,Hsize(4)/2];
Asize = [100*3,100+40];
MaxSIZE = [Hsize(3) Hsize(4)]*0.8;
factor = MaxSIZE./Asize;
factornew = min... |
5e614276d064bf2cf9757216e69bf2b31ad678a7bc7ab31d3524d9dd38971c6b | MATLAB | 85,945 | 1,923 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%3D Tumor Particle Model(TPM) with Immune Response V 1p5_1p8
%Update 2019/09/11
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% This code can simulate any number of cells within any time period using a
% Bro... |
bef668e8f36e7045756100a3bc912479db95bcad906174621635ec51826922d4 | MATLAB | 86,883 | 2,639 | %% Overview
% The main goal of this pipeline is to process and analyze the OPM
% CFA-correction pilot study results.
%
% The pipeline is built to work on all
% four recordings of the pilot study. For each recording, the
% heartbeats / auditory stimuli are split into a train and test set. A
% cardiac dipole moment (CD... |
5dad2dc42d96e4ab4e261d68f5b3d3ba07da04155220cdbb0f155000357ce4bd | MATLAB | 109,094 | 1,845 | %% thesis figures
% current working directory needs to be /path/to/scripts
mainpath = pwd;
addpath([mainpath filesep 'toolboxes' filesep 'tc_functions'])
addpath([mainpath filesep 'toolboxes' filesep 'fieldtrip'])
addpath([mainpath filesep 'fmriRegAnalysis'])
addpath([mainpath filesep 'scriptTemplates'])
ft_defaults
%... |
641fe5f1ec2693d83e6b086535644b6729416f8abb923d286197b45958322388 | MATLAB | 113,244 | 2,363 | function [] = NeuroAnalysis_BehavioralParametricSweepBlockExtractTest(sourceFolders)
% Program which processes the data aquired during behavioral paired imaging
% and stimulation experiments.
threshOverride = 0;
warning('off','all')
warning('off','MATLAB:MKDIR:DirectoryExists');
elecPos =... |
424b6f2435be3fdb3309df8e4b868418972a6f649b34709e70b887a87fb440dd | MATLAB | 128,548 | 3,887 | function varargout = ElectroMap(varargin)
% Main function for running ElectroMap.
% Chris O'Shea and Ting Yue Yu, University of Birmingham
% Maintained by Chris O'Shea - Email CXO531@bham.ac.uk for any queries
% Version 1.0
% Release Date -
% For license information, please see 'license.txt' at ...
% Last... |
102f58b4fa624bc94d6a7fb14958267f70376572d3a56eddbe4a2cd6b50053db | MATLAB | 137,201 | 4,115 | function varargout = ElectroMap(varargin)
% Main function for running ElectroMap.
% Chris O'Shea and Ting Yue Yu, University of Birmingham
% Maintained by Chris O'Shea - Email CXO531@bham.ac.uk for any queries
% Version 1.0
% Release Date -
% For license information, please see 'license.txt' at ...
% Last... |
a8a634db9cb0aebbd295f60d9e67f87b3030d29862a63f48a2c5958f6d2464ab | MATLAB | 144,481 | 4,873 | % VIEW_NII: Create or update a 3-View (Front, Top, Side) of the
% brain data that is specified by nii structure
%
% Usage: status = view_nii([h], nii, [option]) or
% status = view_nii(h, [option])
%
% Where, h is the figure on which the 3-View will be plotted;
% nii is the brain data in NIFTI format;
% o... |
615017a7645730a1d4c17ee6ddebdd7513f898c0c6cc5241ad7b542e899de574 | MATLAB | 147,655 | 3,353 |
% Process all datasets listed in results files and quantify neural response
function IndependentCompareROIsimple218MissALL(sourceFolders,daysTrained,daysThresholds,elecPts,icms)
% javaaddpath 'C:\Program Files\MATLAB\R2019a\java\mij.jar'
% javaaddpath 'C:\Program Files\MATLAB\R201... |
4ba04daaf7ceaf1760ffcde42f61069135a3524523621f042386964b23bd6f72 | MATLAB | 172,619 | 4,416 | % function thresholdMerging()
function thresholdMergingSept2025(daysThresholds83,daysThresholds92,daysThresholds93,daysThresholds98,daysThresholds100,daysThresholds101,contactPos83,contactPos92,contactPos93,contactPos98,contactPos100,contactPos101,sourceFolders83, sourceFolders92, sourceFolders93, sourceFolders98, sou... |
f22bf03792e218d776b5d82880ab9c963cef8a5730c8de2d0b1e017d729d309f | MATLAB | 200,000 | 4,563 |
addpath(genpath('ryhattori-PatchWarp-1.3.3.0'));
addpath(genpath('./rasterplot'));
addpath(genpath('./CaImAn-MATLAB-master'));
addpath(genpath('./natsortfiles'));
addpath(genpath('./imshow3D'));
addpath(genpath('./bfmatlab'));
addpath(genpath('./strel3d'));
addpath(genpath('./mij'));
% calculate trace means... |
fcd19307c597707307ee0a51dd35264bc3fe02b27a8cfd45b6b1ab743c2b0a00 | MATLAB | 200,000 | 4,619 |
cd('S:\Roy');
addpath(genpath('S:\Roy\ryhattori-PatchWarp-1.3.3.0'));
addpath(genpath('S:\Roy\CaImAn-MATLAB-master'));
% calculate trace means and stds
% TODO - report baseline trace means over each session, i.e. see if there is a drifting baseline in each session or for each roi
figGen=0;
fMaxAll = [];
... |
0ba1da74cf83d53e93234ad516599927778c26910bbfe0dfa57efca7103657b4 | MATLAB | 200,001 | 3,569 | %% thesis figures
% current working directory needs to be /path/to/scripts
% mainpath='/project/3018037.01/Experiment3.2_ERC/AnalysisFolder/sharing_collection/scripts';
cd(mainpath)
mainpath = pwd;
addpath([mainpath filesep 'toolboxes' filesep 'tc_functions'])
addpath([mainpath filesep 'toolboxes' filesep 'fieldtrip']... |
0bfa14148bbfdc115ed5bc8cfa678ff7129c6cf57a1e698c4cb8238d0a324bcd | MATLAB | 204,169 | 4,882 | function [Mdl,fMin,Convergence_curve] = optimize_fitrtreebag1(train_x_feature_label_norm,train_y_feature_label_norm,vaild_x_feature_label_norm,vaild_y_feature_label_norm,num_pop,num_iter,method_mti)
% global train_x_feature_label_norm train_y_feature_label_norm vaild_x_feature_label_norm vaild_y_feature_label_norm
... |
2857d6abcc5a896aafcd74a67660f21b37f7d286e4702a39463a1f1ad9a687a9 | MATLAB | 204,238 | 4,826 | function [Mdl2,fMin,Convergence_curve,Loss2,pos] = optimize_fitrCNN_BILSTM_att(p_train1,train_y_feature_label_norm,p_vaild1,vaild_y_feature_label_norm,num_pop,num_iter,method_mti,max_epoch,min_batchsize,attention_label,attention_head)
% global train_x_feature_label_norm train_y_feature_label_norm vaild_x_feature_lab... |
d8c9d767662490bcbf033c794e096808ca5abe443d42fa594a272c9bc7cb7418 | Mathematica | 458 | 10 | data = SemanticImport["F:\\promec\\Animesh\\Pseudomonas\\_Pseudomonas_ 1\\140605_Pseudomonas_O1_K0K6-(2)_Proteins.txt",Delimiters -> "\t", HeaderLines -> 1]
data[All, "Abundances*"]
Plot[%]
Histogram[data[All, "Intensity", Log2]]
FeatureExtract[data[All, "Intensity", Log2+1]]
FindClusters[data[All, "Intensity", Log2+1]... |
c1c79550e185cb31698b1872374796b0bc814987bc497b6ca20005d8e8ed597e | Mathematica | 1,228 | 26 | (*
https://blog.wolfram.com/2019/08/22/embracing-uncertainty-better-model-selection-with-bayesian-linear-regression/
*)
CloudConnect["sharma.animesh@gmail.com","xxxx"]
BayesianLinearRegression = ResourceFunction["BayesianLinearRegression"]
Mean[data]
plot = ListPlot[data, PlotStyle -> Red]
fit = N@BayesianLinearRegress... |
b1de47806166d3f35533bd6bd8846b0a78fddc85f8bd1449745b7e7b7c5bff4a | Mathematica | 2,429 | 31 | (*https://www.wolfram.com/wolfram-u/multiparadigm-data-science/wrangle.html*)
twitter = ServiceConnect["Twitter", SaveConnection -> True]
aniTweets = twitter["TweetList", "Username" -> "animesh1977", MaxItems -> 5000, "Elements" -> "FullData"]
Save["aniTweets", aniTweets]
RandomSample[aniTweets, 5]
%[[5]]
Norma... |
fc1ea32e22b8e6984aa20b74c0ee9bc3d783384e39dda82c5f2c76885833fcae | Mathematica | 7,606 | 137 | 9+9
(Binomial[3787,7]*Binomial[320,15])/Binomial[4107,320]
+(Binomial[3787,16]*Binomial[320,6])/Binomial[4107,320]
+(Binomial[3787,17]*Binomial[320,5])/Binomial[4107,320]
+(Binomial[3787,18]*Binomial[320,4])/Binomial[4107,320]
+(Binomial[3787,19]*Binomial[320,3])/Binomial[4107,320]
+(Binomial[3787,20]*Binomial[320,2])/... |
ffff4f146b5480ee3b068b8bf7f66b067407243f6a8fd1f27888f9e1a80d2be9 | Mathematica | 33,601 | 802 | (* Content-type: application/vnd.wolfram.mathematica *)
(*** Wolfram Notebook File ***)
(* http://www.wolfram.com/nb *)
(* CreatedBy='Mathematica 13.3' *)
(*CacheID: 234*)
(* Internal cache information:
NotebookFileLineBreakTest
NotebookFileLineBreakTest
NotebookDataPosition[ 158, 7]
NotebookDataLengt... |
c1ff2862eea515ad2bf3fc1fb28a6f0815200b2fcb7d007f41d3fcb18ef7396c | Perl | 87 | 5 | use imports_b;
use imports_a;
$x = imports_bc::new_B();
imports_ac::A_hello($x);
|
8bbfcee8f5bb736b6e74c9e72cddd5f43e8fadae8dbcde3daed7f6c77ea15950 | Perl | 107 | 5 | while(<>){
chomp;
system("wget http://www.rcsb.org/pdb/files/$_\.pdb.gz");
}
system("gunzip *.gz");
|
2cb991f7403c861c54ed525be5295969f66226bc4028dce7ef0d5732e0b9f61a | Perl | 112 | 8 | #!/usr/bin/perl
open f1,"genscanresult.txt";
while($line=<f1>)
{
$linenew=uc($line);
print $linenew;
}
|
caeb75e46e7425ba92ccd6b6edf71303b0395cd23aa860edb5b09f2be7ec4402 | Perl | 112 | 2 | while(<>){@t=split(/\s+/,$_);$len=(@t);if($len==2){print "@t[0] NA NA NA NA @t[1] @t[2]\n";}else{print $_;}}
|
e79f1a61f1d16907210c416201f1e04184234632470bd397c20021886ba4d036 | Perl | 123 | 8 | #!/usr/bin/perl -w
$_="";
read(STDIN, $_, 9999999);
s/\s*\(\@pxref{[^}]*}\)//g;
s/\s*\@xref{[^}]*}.//g;
s/,\././g;
print;
|
63b108b8613f06725f9df9da78d6e79b231d8514d15c00d664f8981b032c90ee | Perl | 126 | 8 | #!/bin/perl -- # -*- Perl -*-
# Charset hacking...
while (<>) {
s/\&\#(\d+);/sprintf("\\U-%04X;", $1)/egs;
print;
}
|
1b0e47ab8fdd69b11ba81ab30550c1b4e70f615319ff2c3d483dcd35cd668ff7 | Perl | 128 | 9 | use inherit;
$der = new inherit::CDerived();
$str = $der->Foo();
if ($str != "CBase::Foo") {
die "test failed";
}
|
08c1678725290c5f25ace0bfbdf034a4b11a59372bc27424a7d993f04c6f2b7e | Perl | 167 | 7 | while(<>){
chomp;
@t=split(/\t/);
@tt=split(/\-/,@t[5]);
if($t[0]>80 && (@t[4]/@tt[0]>0.9 && @t[4]/@tt[0]<1.1)){print "@t[0]\t@t[4]\t@t[5]\t@t[6]\t@t[7]\n";}
}
|
553010cc48489e8e17d171a1d9854a93f68e720dc143144d7302964e450747f9 | Perl | 168 | 9 | #!/usr/bin/perl
#@base=qw/A T C G/;
open(F,"annofgeneshpfchr2.html")||die "can't open";
#$seq = "";
while ($line = <F>) {
if($line =~ /^>F/)
{print $line;}
}
|
444b7793aee4bf2ac4b4d17afe04665d013b3c008f7ccc555b994058bacd1049 | Perl | 180 | 14 | #!/usr/bin/perl
print "enter file name \n";
$file=<>;
chomp;
open F1,$file;
while($l=<F1>)
{
chomp($l);
$li=$li.$l;
}
@seq=split(//,$li);
$len=@seq;
print "$len\n";
|
4df538f01831e77f0596028806a4c2bd0223fed66d023cc9bfd3edc5e63f1d0f | Perl | 200 | 11 | $jobid=shift @ARGV;
system("qstat | grep $jobid > $jobid.sjob.txt");
open(F,"$jobid.sjob.txt");
while($l=<F>){
chomp $l;
@t=split(/\./,$l);
print "@t[0]\n";
system("qdel @t[0]");
}
|
a6a0794fb42dd072257b2958314330955742de202f36b6d56cb15fcf23f26f69 | Perl | 204 | 4 | @files=<*.sff>;
system("rm -rf ecol.fna");
foreach (@files) { $c++;print "$c converting file $_\n";system("/usit/titan/u1/ash022/mapasm454_source_11172009/applicationsBin/sffinfo -seq $_ >> ecol.fna");}
|
daec465cbc3fcf78bbd92fac8de7a7f0d44cc7f280c478574b61d99b6c084244 | Perl | 207 | 4 | @files=<*.sff>;
system("rm -rf ecolflow.txt");
foreach (@files) { $c++;print "$c converting file $_\n";system("/usit/titan/u1/ash022/mapasm454_source_11172009/applicationsBin/sffinfo $_ >> ecolflow.txt");}
|
ad0de521b4cb03c90fb15dac24d6998953af166ac5584c3ac3d71458e20b7f75 | Perl | 213 | 15 | use strict;
use Win32;
my $Argument = shift;
my $PathName;
if ($Argument eq "")
{
die "$0: Please give the path name to expand\n";
}
else
{
$PathName = $Argument;
}
print Win32::GetShortPathName($PathName);
|
59d6f4d50620f459924d3f683db4cdb9f6908c3b81522ef332de9fc5a5469385 | Perl | 221 | 13 | #!/usr/bin/perl -w
# use this program to play the examples in this directory
# use: ./beep_player.pl music_file
use strict;
use Audio::Beep;
undef $/;
my $beeper = Audio::Beep->new();
$beeper->play(<>);
|
2f4408ecbb9deb0adc228e15e7a8ae5ee10f966af034a5041252d10c78bf87fc | Perl | 224 | 7 | use SOAP::Lite;
print SOAP::Lite
-> uri('http://www.soaplite.com/Temperatures')
-> proxy('http://services.soaplite.com/temper.cgi')
-> f2c(32)
-> result;
|
e4928c05585d25ddc5eba523b335fb07227d56a0b63cd063a0a14c0b4e3b54d8 | Perl | 225 | 12 | while(<>){
chomp;
@t=split(/\t/);
if(@t[1] eq "NoThreshold"){
print "@t[0]\t@t[2]\n";
@ln=split(/\-/,@t[0]);
$libname=@ln[0];
$dist=@t[2];
system("perl genpairalllib.pl 454AllContigs.fna $libname $dist");
}
}
|
91d47dc301195cf060648d7c766ad83cb9b0b4bf49b03a66daaf8309044cba03 | Perl | 233 | 12 | #!/usr/bin/env perl
$base = shift @ARGV;
@resList = `qstat -u $ENV{"USER"} | grep $base`;
$nres = $#resList + 1;
if ($nres > 0) {
foreach $res (@resList) {
$res =~ /(\d+) .*/;
$pids .= "$1 ";
}
print "$pids\n";
}
|
aad45fda668f59b5d370901a9f33437350d1d26c14d09e44f67036f5d82f4f76 | Perl | 254 | 8 | #!/usr/bin/perl
use Chart::Graph::Gnuplot qw(gnuplot);
print "\nenter the name of file to plot\t::";
$file=<>;
chomp $file;
gnuplot(\%plot,[{"title" => $file,"style" => "lines","type" => "file"},$file],);
system "display untitled-gnuplot.png";
|
70992dabe5c8af7add735adae4b3f22b77d7789f190a3e9db9810bd7777817f9 | Perl | 269 | 11 | #!/usr/bin/perl
#Test primality upto 16 digit number
use strict;
my $test_no=shift @ARGV;
print "$test_no\n";
for(my $i=2;$i<=int(sqrt($test_no));$i++){
if (((int($test_no))%($i))==0) {
die "$test_no is not Prime, divisible by $i";
}
}
print "$test_no is Prime";
|
959447ef8bebfead119eaf0085ad15d42da1375e71892bcef7aa42a790cce166 | Perl | 271 | 10 | edge(a,b).
edge(b,c).
edge(c,d).
edge(d,a).
connect(X,Y) :- edge(X,Y) ; edge(Y,X).
path(A,B,Path) :- vei(A,B,[A],Q),
reverse(Q,Path).
vei(A,B,P,[B|P]) :- connect(A,B).
vei(A,B,Visited,Path) :- connect(A,C),C \== B,\+member(C,Visited),vei(C,B,[C|Visited],Path). |
e5f648d68c3e6d8f92a3fe9cc8a930b41d1a8ee9259c5b783818605c57da5886 | Perl | 273 | 12 | while(<>){
chomp;
@t=split(/\s+/,$_);
if(@t[3] ne "NA" and @t[4] ne "NA" and @t[3] ne "" and @t[4] ne ""){
$c++;
$name_gene="\$MIRA$c";
print " NEWBLER @t[3]..@t[4]\n";
print " TEST4 @t[3]..@t[4]\n";
push(@name,$name_gene);
}
}
|
3e3b948785b1af0045fcc3b4336aaea99ada51a82e500f03c8ada3ee99858ae8 | Perl | 283 | 9 | use Bio::KEGG::API;
my $api = Bio::KEGG::API->new();
print $api->database_info(database => 'hsa');
__END__
curl "http://cactus.nci.nih.gov/chemical/structure/(9Z,12Z,15Z)-Octadeca-9,12,15-trienoic%20acid/smiles"
grep "^C" smiles* | awk -F ':' '{print $2}' > s.txt
|
4f3edb7570d228cf628074dfa30223cbb596ef960f5ff7cf2ea3a1086079c4f6 | Perl | 287 | 13 | use warnings;
use strict;
open(F1,$ARGV[0]);
my @list=<F1>;
@list = sort { uc($a) cmp uc($b) } @list;
my %match;
for(my $c1=0;$c1<=$#list;$c1++){
$list[$c1]=~s/\n|\r//g;
my @tmp1=split(/GN\=/,$list[$c1]);
my @tmp2=split(/\s+/,$tmp1[1]);
print "$tmp2[0],$list[$c1]\n"
}
|
52bb4959cb34576baaed34c4071a00fe27789c681a373b72e8ab8ff236bf2c5f | Perl | 287 | 17 | #!/usr/bin/perl
open f1,"AC109365.txt";
while($line=<f1>)
{
chomp $line;
if($line=~/^>/)
{print "$line\t";}
if($line=~/Score/)
{print "$line\t";}
if($line=~/Identities/)
{print "$line\t";}
if($line=~/Query: /)
{print "$line\t";}
if($line=~/Sbjct/)
{print "$line\n";}
}
|
3922fefb987e917eea066f0fbf16bdcc4eec747c5e8e10ff3f7a7f642cc1535f | Perl | 296 | 12 | use lib '/home/animesh/export/graph/Google-Chart-0.09000_04/lib';
use Google::Chart;
my $chart = Google::Chart->new(
type => "Bar",
data => [ 1, 2, 3, 4, 5 ]
);
print $chart->as_uri, "\n"; # or simply print $chart, "\n"
$chart->render_to_file( filename => 'filename.png' );
|
694af5e1dc51130a3cff5eff50bcac32eeedef4d21f85d5f9efde8ae12e300f7 | Perl | 309 | 14 | #!/usr/bin/perl -w
chdir("..");
system("ls org/emboss/jemboss/*java org/emboss/jemboss/*/*java org/emboss/jemboss/*/*/*java > x");
open(IN, "x");
my $java;
while($line = <IN>)
{
chomp($line);
$line =~ /(.*)(\.java)/;
$java = $java." ";
$java = $java.$1;
}
system("rm -rf x");
print $java;
|
89f5c0e8763085d24475ec88ff6970607c6fb8d4ae30cfa6dfd9b259356eb3c3 | Perl | 317 | 14 | #!/usr/bin/perl -w
use strict;
use Bio::DB::Registry;
use Bio::SeqIO;
use strict;
my $registry = new Bio::DB::Registry();
print "services are ", join(',', $registry->services), "\n";
my $db = $registry->get_database("embl");
my $seq = $db->get_Seq_by_id("J02231");
my $out = new Bio::SeqIO;
$out->write_seq($seq);
|
71cff7b6597d3c5bb9dffc2bb63e9cb7fffab7e15bda9b54eb44591485f57019 | Perl | 322 | 17 | while(<>){
split(/\t/);
if(@_[5]>@_[6]){$s=@_[6];$e=@_[5];print "Rev\t"}
else{$s=@_[5];$e=@_[6];}
#for($c=$s;$c<=$e;$c++){
#push(@pos,$c);
#print "$c\n";
$pos{$c}++;
#}
print "@_[4]>@_[7]\t@_[5]>@_[6]\n";
}
#foreach (keys %pos) {print "$_\t$pos{$_}\n";}
__END__
for($c=0;$c<=$#pos;$c++){
print "@pos[$c]";
}... |
c19a4613b5a52545cdbfd3f241f3015a7ac087d84f24a3fa09b3742252a75fab | Perl | 323 | 18 | #!/usr/bin/perl
use strict;
use warnings;
use lib qw( lib ../../lib );
use Harness::Hook;
use TAP::Harness;
use File::Spec;
$| = 1;
my $harness = TAP::Harness->new;
# Install the hook
Harness::Hook->new($harness);
$harness->runtests(
File::Spec->catfile( split( /\//, '../../t/000-load.t' ) ) )... |
a2260258580ac3a4a2fe787bb13a2a4fdf57767c91c1f1b0a0ebe646bd1fb6a4 | Perl | 336 | 25 | $ctg="7180001513595";
while(<>){
chomp;
@t=split(/\t/);
if($ctg eq @t[1]){
$start=@t[2];
$end=@t[3];
if($start>$end){
$tmp=$start;
$start=$end;
$end=$start;
}
$read{@t[0]}++;
if($read{@t[0]}==1){
for($c=$start;$c<=$end;$c++){
$depth{$c}++;
}
}
}
}
foreach (keys %depth) {
print "$_\t$de... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.