plateform stringclasses 1
value | repo_name stringlengths 13 113 | name stringlengths 3 74 | ext stringclasses 1
value | path stringlengths 12 229 | size int64 23 843k | source_encoding stringclasses 9
values | md5 stringlengths 32 32 | text stringlengths 23 843k |
|---|---|---|---|---|---|---|---|---|
github | akhanf/vasst-dev-master | bresenham_line3d.m | .m | vasst-dev-master/tools/matlab/nifti_tools/bresenham_line3d.m | 4,682 | utf_8 | f2e52d1f3ac9779b22baf3bb4d2ac201 | % Generate X Y Z coordinates of a 3D Bresenham's line between
% two given points.
%
% A very useful application of this algorithm can be found in the
% implementation of Fischer's Bresenham interpolation method in my
% another program that can rotate three dimensional image volume
% with an affine matrix:
... |
github | akhanf/vasst-dev-master | make_nii.m | .m | vasst-dev-master/tools/matlab/nifti_tools/make_nii.m | 7,105 | utf_8 | 6b1565392965b164217621e71d213ddd | % Make NIfTI structure specified by an N-D matrix. Usually, N is 3 for
% 3D matrix [x y z], or 4 for 4D matrix with time series [x y z t].
% Optional parameters can also be included, such as: voxel_size,
% origin, datatype, and description.
%
% Once the NIfTI structure is made, it can be saved into NIfT... |
github | akhanf/vasst-dev-master | verify_nii_ext.m | .m | vasst-dev-master/tools/matlab/nifti_tools/verify_nii_ext.m | 1,721 | utf_8 | 0339aeb8d7286e4f08165c9eeeb4c2cd | % Verify NIFTI header extension to make sure that each extension section
% must be an integer multiple of 16 byte long that includes the first 8
% bytes of esize and ecode. If the length of extension section is not the
% above mentioned case, edata should be padded with all 0.
%
% Usage: [ext, esize_total] = ... |
github | akhanf/vasst-dev-master | get_nii_frame.m | .m | vasst-dev-master/tools/matlab/nifti_tools/get_nii_frame.m | 4,497 | utf_8 | cc9b1b92f34e5ae67dc34c35a5174c75 | % Return time frame of a NIFTI dataset. Support both *.nii and
% *.hdr/*.img file extension. If file extension is not provided,
% *.hdr/*.img will be used as default.
%
% It is a lightweighted "load_nii_hdr", and is equivalent to
% hdr.dime.dim(5)
%
% Usage: [ total_scan ] = get_nii_frame(filename)
%
... |
github | akhanf/vasst-dev-master | flip_lr.m | .m | vasst-dev-master/tools/matlab/nifti_tools/flip_lr.m | 3,568 | utf_8 | d95b62698d44a65a3c2f02fbabc632ac | % When you load any ANALYZE or NIfTI file with 'load_nii.m', and view
% it with 'view_nii.m', you may find that the image is L-R flipped.
% This is because of the confusion of radiological and neurological
% convention in the medical image before NIfTI format is adopted. You
% can find more details from:
%
%... |
github | akhanf/vasst-dev-master | save_nii.m | .m | vasst-dev-master/tools/matlab/nifti_tools/save_nii.m | 9,690 | utf_8 | ed292054cab74afaf953455bfbc200aa | % Save NIFTI dataset. Support both *.nii and *.hdr/*.img file extension.
% If file extension is not provided, *.hdr/*.img will be used as default.
%
% Usage: save_nii(nii, filename, [old_RGB])
%
% nii.hdr - struct with NIFTI header fields (from load_nii.m or make_nii.m)
%
% nii.img - 3D (or 4D) matrix o... |
github | akhanf/vasst-dev-master | rri_file_menu.m | .m | vasst-dev-master/tools/matlab/nifti_tools/rri_file_menu.m | 4,153 | utf_8 | c9faa3905c642854eeed98ab8b02998e | % Imbed a file menu to any figure. If file menu exist, it will append
% to the existing file menu. This file menu includes: Copy to clipboard,
% print, save, close etc.
%
% Usage: rri_file_menu(fig);
%
% rri_file_menu(fig,0) means no 'Close' menu.
%
% - Jimmy Shen (jimmy@rotman-baycrest.on.ca)
%
... |
github | akhanf/vasst-dev-master | reslice_nii.m | .m | vasst-dev-master/tools/matlab/nifti_tools/reslice_nii.m | 10,138 | utf_8 | ea18d2f994fd5d9989449feaced1e4dd | % The basic application of the 'reslice_nii.m' program is to perform
% any 3D affine transform defined by a NIfTI format image.
%
% In addition, the 'reslice_nii.m' program can also be applied to
% generate an isotropic image from either a NIfTI format image or
% an ANALYZE format image.
%
% The resliced N... |
github | akhanf/vasst-dev-master | save_untouch_nii.m | .m | vasst-dev-master/tools/matlab/nifti_tools/save_untouch_nii.m | 6,726 | utf_8 | cb98e2799abc112dca5b10078bde09bf | % Save NIFTI or ANALYZE dataset that is loaded by "load_untouch_nii.m".
% The output image format and file extension will be the same as the
% input one (NIFTI.nii, NIFTI.img or ANALYZE.img). Therefore, any file
% extension that you specified will be ignored.
%
% Usage: save_untouch_nii(nii, filename)
%
%... |
github | akhanf/vasst-dev-master | view_nii.m | .m | vasst-dev-master/tools/matlab/nifti_tools/view_nii.m | 144,481 | utf_8 | 8ea68ec34d3a6bec721497afb56cfb54 | % 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... |
github | akhanf/vasst-dev-master | mat_into_hdr.m | .m | vasst-dev-master/tools/matlab/nifti_tools/mat_into_hdr.m | 2,691 | utf_8 | 847d96698f45f7c5e7decbb3a0c3187f | %MAT_INTO_HDR The old versions of SPM (any version before SPM5) store
% an affine matrix of the SPM Reoriented image into a matlab file
% (.mat extension). The file name of this SPM matlab file is the
% same as the SPM Reoriented image file (.img/.hdr extension).
%
% This program will convert the ANALYZE 7.5 SPM... |
github | akhanf/vasst-dev-master | xform_nii.m | .m | vasst-dev-master/tools/matlab/nifti_tools/xform_nii.m | 18,628 | utf_8 | e39c421e7f117cbc81c56e9d023774a3 | % internal function
% 'xform_nii.m' is an internal function called by "load_nii.m", so
% you do not need run this program by yourself. It does simplified
% NIfTI sform/qform affine transform, and supports some of the
% affine transforms, including translation, reflection, and
% orthogonal rotation (N*90 ... |
github | akhanf/vasst-dev-master | make_ana.m | .m | vasst-dev-master/tools/matlab/nifti_tools/make_ana.m | 5,665 | utf_8 | 37d574b277823f941138c9548127d720 | % Make ANALYZE 7.5 data structure specified by a 3D or 4D matrix.
% Optional parameters can also be included, such as: voxel_size,
% origin, datatype, and description.
%
% Once the ANALYZE structure is made, it can be saved into ANALYZE 7.5
% format data file using "save_untouch_nii" command (for more de... |
github | akhanf/vasst-dev-master | extra_nii_hdr.m | .m | vasst-dev-master/tools/matlab/nifti_tools/extra_nii_hdr.m | 8,085 | utf_8 | 4f76a8a66736025a0acf3efa15a2d2aa | % Decode extra NIFTI header information into hdr.extra
%
% Usage: hdr = extra_nii_hdr(hdr)
%
% hdr can be obtained from load_nii_hdr
%
% NIFTI data format can be found on: http://nifti.nimh.nih.gov
%
% - Jimmy Shen (jimmy@rotman-baycrest.on.ca)
%
function hdr = extra_nii_hdr(hdr)
switch hdr.dime.da... |
github | akhanf/vasst-dev-master | rri_xhair.m | .m | vasst-dev-master/tools/matlab/nifti_tools/rri_xhair.m | 2,300 | utf_8 | 95954b8cd43e01fba5c4b2f335be1780 | % rri_xhair: create a pair of full_cross_hair at point [x y] in
% axes h_ax, and return xhair struct
%
% Usage: xhair = rri_xhair([x y], xhair, h_ax);
%
% If omit xhair, rri_xhair will create a pair of xhair; otherwise,
% rri_xhair will update the xhair. If omit h_ax, current axes will
% b... |
github | akhanf/vasst-dev-master | save_untouch_nii_hdr.m | .m | vasst-dev-master/tools/matlab/nifti_tools/save_untouch_nii_hdr.m | 8,721 | utf_8 | 0d396eaeebb6114f24d56ab74a8299cf | % internal function
% - Jimmy Shen (jimmy@rotman-baycrest.on.ca)
function save_nii_hdr(hdr, fid)
if ~isequal(hdr.hk.sizeof_hdr,348),
error('hdr.hk.sizeof_hdr must be 348.');
end
write_header(hdr, fid);
return; % save_nii_hdr
%------------------------------------------------... |
github | akhanf/vasst-dev-master | expand_nii_scan.m | .m | vasst-dev-master/tools/matlab/nifti_tools/expand_nii_scan.m | 1,381 | utf_8 | 0715d668d046bcc608ea78cd0c2089bd | % Expand a multiple-scan NIFTI file into multiple single-scan NIFTI files
%
% Usage: expand_nii_scan(multi_scan_filename, [img_idx], [path_to_save])
%
% NIFTI data format can be found on: http://nifti.nimh.nih.gov
%
% - Jimmy Shen (jimmy@rotman-baycrest.on.ca)
%
function expand_nii_scan(filename, img_idx, n... |
github | akhanf/vasst-dev-master | load_untouch_header_only.m | .m | vasst-dev-master/tools/matlab/nifti_tools/load_untouch_header_only.m | 7,255 | utf_8 | f1210f851ab6610e7656121194cb5c8b | % Load NIfTI / Analyze header without applying any appropriate affine
% geometric transform or voxel intensity scaling. It is equivalent to
% hdr field when using load_untouch_nii to load dataset. Support both
% *.nii and *.hdr file extension. If file extension is not provided,
% *.hdr will be used as default.... |
github | akhanf/vasst-dev-master | bipolar.m | .m | vasst-dev-master/tools/matlab/nifti_tools/bipolar.m | 2,239 | utf_8 | c860ec93d96b6ab636c985280d79958d | %BIPOLAR returns an M-by-3 matrix containing a blue-red colormap, in
% in which red stands for positive, blue stands for negative,
% and white stands for 0.
%
% Usage: cmap = bipolar(M, lo, hi, contrast); or cmap = bipolar;
%
% cmap: output M-by-3 matrix for BIPOLAR colormap.
% M: number of shades in th... |
github | akhanf/vasst-dev-master | save_nii_hdr.m | .m | vasst-dev-master/tools/matlab/nifti_tools/save_nii_hdr.m | 9,497 | utf_8 | 66a99df0cb0f3c1f44c6e36dcd13cddf | % internal function
% - Jimmy Shen (jimmy@rotman-baycrest.on.ca)
function save_nii_hdr(hdr, fid)
if ~exist('hdr','var') | ~exist('fid','var')
error('Usage: save_nii_hdr(hdr, fid)');
end
if ~isequal(hdr.hk.sizeof_hdr,348),
error('hdr.hk.sizeof_hdr must be 348.');
end
... |
github | akhanf/vasst-dev-master | writeTractsToVTK_withUID.m | .m | vasst-dev-master/tools/matlab/tractography/writeTractsToVTK_withUID.m | 1,235 | utf_8 | d0a38005f371a84cccd0250b52b1fe3e | %writing custom colored vtk -- given tracts cell, and color cell
function writeTractsToVTK_withUID(in_tracts,in_extra,out_vtk)
%first write out basic vtk point data
points=cat(1,in_tracts{:});
%for testing:
%scalars=abs(mean(points,2)); %for testing
points_vec=reshape(points',size(points,1)*3,1);
lines=[];
%zero... |
github | akhanf/vasst-dev-master | writeTractsToVTK_withScalars.m | .m | vasst-dev-master/tools/matlab/tractography/writeTractsToVTK_withScalars.m | 1,436 | utf_8 | b7bd511947690074e0406087072dd0cf | %writing custom colored vtk -- given tracts cell, and color cell
function writeTractsToVTK_withScalars(in_tracts,in_scalars_cell,out_vtk)
%first write out basic vtk point data
points=cat(1,in_tracts{:});
%for testing:
%scalars=abs(mean(points,2)); %for testing
points_vec=reshape(points',size(points,1)*3,1);
line... |
github | akhanf/vasst-dev-master | importLabelHierarchy.m | .m | vasst-dev-master/tools/matlab/tractography/importLabelHierarchy.m | 3,876 | utf_8 | 35d16e9590919bf7ac24768d8ebcc21a |
function importLabelHierarchy(in_nrrd,out_folder)
% imports bundle-based rules from synaptive NRRD atlas into nifti files, with contains/excludes
mkdir(out_folder);
[nrrd,meta]=nrrdread(in_nrrd);
nii_file=sprintf('%s.nii.gz',in_nrrd);
system(sprintf('c3d %s -o %s',in_nrrd,nii_file));
nii=load_nifti(nii_file);
delet... |
github | akhanf/vasst-dev-master | read_mrtrix.m | .m | vasst-dev-master/tools/matlab/tractography/read_mrtrix.m | 3,296 | utf_8 | 3ffe4389aff0f4aec0b42d8e40097b1b | function image = read_mrtrix (filename)
% function: image = read_mrtrix (filename)
%
% returns a structure containing the header information and data for the MRtrix
% format image 'filename' (i.e. files with the extension '.mif' or '.mih').
image.comments = {};
f = fopen (filename, 'r');
if (f<1)
disp (['error o... |
github | akhanf/vasst-dev-master | labelTractsHybrid_withClustering.m | .m | vasst-dev-master/tools/matlab/tractography/labelTractsHybrid_withClustering.m | 22,839 | utf_8 | b01339614aae1eb1877dfd374d96ff2a | % cleaner script for tract labelling
% given initial bundles:
function labelTractsHybrid_withClustering ( subj)
%subj='1.2.840.113845.11.1000000001951524609.20130802093226.6697837';
lut_color={'r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','m'};
p... |
github | akhanf/vasst-dev-master | computeTractDistanceMetric_nii.m | .m | vasst-dev-master/tools/matlab/tractography/computeTractDistanceMetric_nii.m | 242 | utf_8 | e4e34b5dd01112622dadea05e6e63c50 |
function computeTractDistanceMetric_nii (in_nii_1,in_nii_2,out_mean_txt,out_haus_txt)
[hausDist meanDist]=computeBundleDistanceMetrics_nii(in_nii_1,in_nii_2);
dlmwrite(out_haus_txt,hausDist);
dlmwrite(out_mean_txt,meanDist);
end
|
github | akhanf/vasst-dev-master | labelTractsHybrid_withClustering_camino.m | .m | vasst-dev-master/tools/matlab/tractography/labelTractsHybrid_withClustering_camino.m | 14,666 | utf_8 | 29fe5f88ad9597951aebd114604ec0e2 | % cleaner script for tract labelling
% given initial bundles:
function labelTractsHybrid_withClustering_camino ( subj)
%subj='1.2.840.113845.11.1000000001951524609.20130802093226.6697837';
lut_color={'r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k',... |
github | akhanf/vasst-dev-master | combineCaminoTractsInVTK.m | .m | vasst-dev-master/tools/matlab/tractography/combineCaminoTractsInVTK.m | 772 | utf_8 | fe960380bea0dcfe3a76be03922eeded | %combine tracts
% left_tracts=readCaminoTracts('Cortico_Spinal_Left_bundle.Bfloat');
% right_tracts=readCaminoTracts('Cortico_Spinal_Right_bundle.Bfloat');
%
% in_tracts{1}='Cortico_Spinal_Left_bundle.Bfloat';
% in_tracts{2}='Cortico_Spinal_Right_bundle.Bfloat';
%
% in_tracts{1}='Arcuate_Left_bundle.Bfloat';
% in_tr... |
github | akhanf/vasst-dev-master | labelTractsHybrid_withClustering_hardi.m | .m | vasst-dev-master/tools/matlab/tractography/labelTractsHybrid_withClustering_hardi.m | 14,667 | utf_8 | b0daddaa2ee0a162285d3a6a4e189d46 | % cleaner script for tract labelling
% given initial bundles:
function labelTractsHybrid_withClustering_hardi ( subj)
%subj='1.2.840.113845.11.1000000001951524609.20130802093226.6697837';
lut_color={'r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','m','r','b','g','c','k','... |
github | akhanf/vasst-dev-master | writeTractsToVTK.m | .m | vasst-dev-master/tools/matlab/tractography/writeTractsToVTK.m | 1,263 | utf_8 | e1fd15aef88f10a8c53b6a97412dc438 | %writing custom colored vtk -- given tracts cell, and color cell
function writeTractsToVTK(in_tracts,in_scalars,out_vtk)
%first write out basic vtk point data
points=cat(1,in_tracts{:});
%for testing:
%scalars=abs(mean(points,2)); %for testing
points_vec=reshape(points',size(points,1)*3,1);
lines=[];
%zeros(size... |
github | akhanf/vasst-dev-master | labelTractsHybrid.m | .m | vasst-dev-master/tools/matlab/tractography/labelTractsHybrid.m | 3,932 | utf_8 | 2704969eef346822eb7a0112a6a8fff4 | % cleaner script for tract labelling
% given initial bundles:
function labelTractsHybrid ( subj)
in_lut_csv='~/pipeline/cfg/labels/FibreBundleLUT.csv';
lut=importdata(in_lut_csv);
%without custom tractography settings:
data_dir=sprintf('%s/dti/synaptive',subj);
whole_brain_bfloat=sprintf('%s/wholebrain.Tracts.Bf... |
github | akhanf/vasst-dev-master | computeTractDistanceMetric.m | .m | vasst-dev-master/tools/matlab/tractography/computeTractDistanceMetric.m | 263 | utf_8 | 5e4a74379f3e18874e3ce2a58170bed9 |
function computeTractDistanceMetric (in_vtk_1,in_vtk_2,out_haus_txt,out_mean_txt)
[hausDist meanDist]=computeBundleDistanceMetrics(readTractsFromVTK(in_vtk_1),readTractsFromVTK(in_vtk_2));
dlmwrite(out_haus_txt,hausDist);
dlmwrite(out_mean_txt,meanDist);
end
|
github | akhanf/vasst-dev-master | getBundleNamesLabelsTractXML.m | .m | vasst-dev-master/tools/matlab/tractography/getBundleNamesLabelsTractXML.m | 835 | utf_8 | 9ccea74a1445e67964c2afd407d09718 |
function [bundle_names,bundle_labels]=getBundleNamesLabelsTractXML (in_xml)
max_java_memory = java.lang.Runtime.getRuntime.maxMemory;
foo=xmlread(in_xml);
bundle_nodes=foo.getElementsByTagName('Data').item(0).getElementsByTagName('Bundles').item(0).getElementsByTagName('Node');
bundle_labels=[];
for i=0:(bundle... |
github | akhanf/vasst-dev-master | combineCaminoTractsInVTK_withLUT.m | .m | vasst-dev-master/tools/matlab/tractography/combineCaminoTractsInVTK_withLUT.m | 1,513 | utf_8 | b18db922c585e613e4160291de775765 | %combine tracts
% left_tracts=readCaminoTracts('Cortico_Spinal_Left_bundle.Bfloat');
% right_tracts=readCaminoTracts('Cortico_Spinal_Right_bundle.Bfloat');
%
% in_tracts{1}='Cortico_Spinal_Left_bundle.Bfloat';
% in_tracts{2}='Cortico_Spinal_Right_bundle.Bfloat';
%
% in_tracts{1}='Arcuate_Left_bundle.Bfloat';
% in_tr... |
github | akhanf/vasst-dev-master | guiMain.m | .m | vasst-dev-master/tools/matlab/SpectralClustering/files/GUI/guiMain.m | 19,908 | utf_8 | 77ee8f8b916ccc8e46f3e23870ba799a | function varargout = guiMain(varargin)
% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name', mfilename, ...
'gui_Singleton', gui_Singleton, ...
'gui_OpeningFcn', @guiMain_OpeningFcn, ...
'gui_OutputFcn', @guiMain_Out... |
github | akhanf/vasst-dev-master | relativepath.m | .m | vasst-dev-master/tools/matlab/SpectralClustering/files/other/relativepath.m | 2,986 | utf_8 | e3ec67916f778896a1bf6f7229c68b8c | function rel_path = relativepath( tgt_path, act_path )
%RELATIVEPATH returns the relative path from an actual path to the target path.
% Both arguments must be strings with absolute paths.
% The actual path is optional, if omitted the current dir is used instead.
% In case the volume drive letters don't mat... |
github | akhanf/vasst-dev-master | calcRMANOVAAllDat.m | .m | vasst-dev-master/hipp_reg_proj/calcRMANOVAAllDat.m | 8,938 | utf_8 | 5b7901ebd76a87364b72a8324cfdaf17 | % performs a repeated measures ANOVA using all data
function calcRMANOVAAllDat(subjList,transformationModels,costFunctions)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
templates=importdata(subjList);
model=importdata(transformationModels);
cost=importdata(costFunctions);
data_vec=[];
hemi_v... |
github | akhanf/vasst-dev-master | compareCentroid.m | .m | vasst-dev-master/hipp_reg_proj/compareCentroid.m | 9,094 | utf_8 | 3416f9293b0c55cc2af77a5dc05cd6bc | % generates centroids and compares their locations between a template
% subject and each subject in a subject list
function compareCentroid(template,subjList,costFunction,transformationModel)
% import subject list
subjects=importdata(subjList);
% remove template from subject list
for i=1:length(subjects)
if temp... |
github | akhanf/vasst-dev-master | genCheckerboard.m | .m | vasst-dev-master/hipp_reg_proj/genCheckerboard.m | 3,162 | utf_8 | dc6c220e6b45c94db67296ac67a2d020 | % generates checkerboard files from input AP and PD maps
function genCheckerboard(subjList,path)
% import subject list
subjects=importdata(subjList);
for i=1:length(subjects)
% set file paths/names
left_AP=sprintf('%s/%s/labels/t2/AP/AP.l.nii.gz',path,subjects{i});
left_PD=sprintf('%s/%s/labels/t2/P... |
github | akhanf/vasst-dev-master | findBestAndWorstReg_perSubj.m | .m | vasst-dev-master/hipp_reg_proj/findBestAndWorstReg_perSubj.m | 3,649 | utf_8 | 9bd71c30fd72f968b6753c4d51b5dac5 | % performs a repeated measures ANOVA using all data
function findBestAndWorstReg_perSubj(subjList,models,costs)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
subjects=importdata(subjList);
model=importdata(models);
cost=importdata(costs);
template='V073';
vecL=zeros(94,88);
vecR=zeros(... |
github | akhanf/vasst-dev-master | calcAvgDistPerSubj.m | .m | vasst-dev-master/hipp_reg_proj/calcAvgDistPerSubj.m | 2,891 | utf_8 | 046c9112cbf771eef4052733d55cec2e | % calculate average Euclidean distance for transformations to the target
% input template for each bin
function calcAvgDistPerSubj(template,subjList, transformationModel, costFunction)
% import subject list
subjects=importdata(subjList);
% remove template from subject list
for i=1:length(subjects)
if template==s... |
github | akhanf/vasst-dev-master | calcBinVol.m | .m | vasst-dev-master/hipp_reg_proj/calcBinVol.m | 1,685 | utf_8 | d5fcf80146c3073fca516dfc05d08d07 | % calculate volumes of each checkerboard bin
% path is path to subject folders
function calcBinVol(subjList,path)
subjects=importdata(subjList);
for i=1:length(subjects)
left_checkerboard=sprintf('%s/%s/labels/t2/checkerboard/checkerboard.l.10.reorient.06mm.affineAtlasSpace.crop.corr.nii.gz',path,subjects{i});
... |
github | akhanf/vasst-dev-master | compareCentroidIntensityWise.m | .m | vasst-dev-master/hipp_reg_proj/compareCentroidIntensityWise.m | 5,215 | utf_8 | 01c2868d0990830060fd70da43df8828 | % calculates Euclidean distance in mm of intensity-based centroids from the
% template and transformed checkerboards
function compareCentroidIntensityWise(template,subjList,costFunction,transformationModel)
% import subject list
subjects=importdata(subjList);
% remove template from subject list
for i=1:length(subjec... |
github | akhanf/vasst-dev-master | genErrorHeatMap.m | .m | vasst-dev-master/hipp_reg_proj/genErrorHeatMap.m | 3,404 | utf_8 | a67bd6737ca62295bf597fd2eebf9d19 | % generate heat maps for each combination of transformation model and cost
% function
function genErrorHeatMap(transformationModel,costFunction,lookupTable)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
lookup=importdata(lookupTable,' ');
if strcmp(costFunction, "t1") || strcmp(costFunction,... |
github | akhanf/vasst-dev-master | calcANOVAAllDat.m | .m | vasst-dev-master/hipp_reg_proj/calcANOVAAllDat.m | 4,477 | utf_8 | 1356b125bb29ee2fa40b91ab03bec132 | % performs anova across all non-collapsed data values using the factors of
% transformation model, cost function, and hemisphere
function calcANOVAAllDat(subjlist,transformationModels,costFunctions)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
templates=importdata(subjlist);
model=importdata(... |
github | akhanf/vasst-dev-master | calcTTest_APBin_avgedError.m | .m | vasst-dev-master/hipp_reg_proj/calcTTest_APBin_avgedError.m | 13,011 | utf_8 | f10dba428a83dfe08716fd8dee5c2877 | % performs a paired t-test using data collapsed into 10 AP bins
% (i.e. collapsed in the PD dimension) for each hemisphere
function calcTTest_APBin_avgedError(subjList,transformationModel1,costFunction1,transformationModel2,costFunction2,AP_bin)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
te... |
github | akhanf/vasst-dev-master | calcTTest_APBin_bothHemi.m | .m | vasst-dev-master/hipp_reg_proj/calcTTest_APBin_bothHemi.m | 12,546 | utf_8 | 916e547e0c201d6377580f7271f0524f | % performs a paired t-test using data collapsed into 10 AP bins
% (i.e. collapsed in the PD dimension) for each hemisphere
function calcTTest_APBin_bothHemi(subjList,transformationModel1,costFunction1,transformationModel2,costFunction2,AP_bin)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
temp... |
github | akhanf/vasst-dev-master | calcRMANOVA_APBin.m | .m | vasst-dev-master/hipp_reg_proj/calcRMANOVA_APBin.m | 11,411 | utf_8 | 23b27858a873d6e39a3b9ac37ff2936b | % performs a repeated measures ANOVA using data collapsed into 10 AP bins
% (i.e. collapsed in the PD dimension)
function calcRMANOVA_APBin(subjList,transformationModels,costFunctions,AP_bin)
% performs a repeated measures ANOVA using all data
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
temp... |
github | akhanf/vasst-dev-master | calcAvgDistPerCombo.m | .m | vasst-dev-master/hipp_reg_proj/calcAvgDistPerCombo.m | 2,768 | utf_8 | f84e0d03fdcfa801f3ad8885f23ccd51 | % calculate average Euclidean distance for transformation model/cost
% function combinations
function calcAvgDistPerCombo(subjList,transformationModel,costFunction)
% import subject list
subjects=importdata(subjList);
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
if strcmp(costFunction, "t1"... |
github | akhanf/vasst-dev-master | findBestAndWorstReg.m | .m | vasst-dev-master/hipp_reg_proj/findBestAndWorstReg.m | 4,198 | utf_8 | 6c311fabe95c87b9d2bb9e7477118602 | % performs a repeated measures ANOVA using all data
function findBestAndWorstReg(subjList,models,costs)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
templates=importdata(subjList);
model=importdata(models);
cost=importdata(costs);
% vecL=zeros(94,1056);
vecL=zeros(94,96
% vecR=zeros(9... |
github | akhanf/vasst-dev-master | calcTTest_APBin.m | .m | vasst-dev-master/hipp_reg_proj/calcTTest_APBin.m | 11,362 | utf_8 | 6b7056ffb5cb876e050bcd9f9efb299f | % performs a paired t-test using data collapsed into 10 AP bins
% (i.e. collapsed in the PD dimension) for each hemisphere
function calcTTest_APBin(subjList,transformationModel1,costFunction1,transformationModel2,costFunction2,AP_bin)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
templates=imp... |
github | akhanf/vasst-dev-master | calcRMANOVAAllDat_withBins.m | .m | vasst-dev-master/hipp_reg_proj/calcRMANOVAAllDat_withBins.m | 9,290 | utf_8 | cad71acfe34c9b1733ac235436eace32 | % performs a repeated measures ANOVA using all data
function calcRMANOVAAllDat_withBins(subjList,transformationModels,costFunctions)
dir=('~/khangrp/projects/unsorted/averageDeepBrain7T/7THippAtlas/');
templates=importdata(subjList);
model=importdata(transformationModels);
cost=importdata(costFunctions);
data_vec=[... |
github | akhanf/vasst-dev-master | logbesseli0.m | .m | vasst-dev-master/noddi_mcr/src/models/logbesseli0.m | 873 | utf_8 | e449fedfcad00a28c87a93005c46298b | % Computes log(besseli(0,x)) robustly. Computing it directly causes
% numerical problems at high x, but the function has asymptotic linear
% behaviour, which we approximate here for high x.
%
% author: Daniel C Alexander (d.alexander@ucl.ac.uk)
%
function lb0 = logbesseli0(x)
% For very large arguments to b... |
github | akhanf/vasst-dev-master | subsasgn.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/subsasgn.m | 4,673 | utf_8 | 75e22b274b00f49cdbe447cced1bee4d | function obj = subsasgn(obj,subs,dat)
% Overloaded subsasgn function for file_array objects.
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: subsasgn.m 4136 2010-12-09 22:22:28Z guillaume
%
% niftilib $Id: subsasgn.m,v 1.3 ... |
github | akhanf/vasst-dev-master | subsref.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/subsref.m | 5,387 | utf_8 | 6eee1a7d14f7230c71555693bd07e112 | function varargout=subsref(obj,subs)
% SUBSREF Subscripted reference
% An overloaded function...
%__________________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: subsref.m 4136 2010-12-09 22:22:28Z guillaume
%
% niftilib $Id: subsref.m,v ... |
github | akhanf/vasst-dev-master | disp.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/disp.m | 996 | utf_8 | 5efc6c65e6295044a165cc12e7077ef3 | function disp(obj)
% Display a file_array object
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: disp.m 4136 2010-12-09 22:22:28Z guillaume
%
% niftilib $Id: disp.m,v 1.3 2012/03/22 18:36:33 fissell Exp $
%
if numel(stru... |
github | akhanf/vasst-dev-master | offset.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/private/offset.m | 808 | utf_8 | badb9c78b56841cd9f8553919b77720b | function varargout = offset(varargin)
% Format
% For getting the value
% dat = offset(obj)
%
% For setting the value
% obj = offset(obj,dat)
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: offset.m 1143 2008-02-07 19:33:33Z s... |
github | akhanf/vasst-dev-master | scl_slope.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/private/scl_slope.m | 797 | utf_8 | 41bca5b57d866a8d16de7099ff6223bf | function varargout = scl_slope(varargin)
% Format
% For getting the value
% dat = scl_slope(obj)
%
% For setting the value
% obj = scl_slope(obj,dat)
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: scl_slope.m 1143 2008-02-07... |
github | akhanf/vasst-dev-master | scl_inter.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/private/scl_inter.m | 798 | utf_8 | 38e198f4aad63b893f8b5cfefd9df6ba | function varargout = scl_inter(varargin)
% Format
% For getting the value
% dat = scl_inter(obj)
%
% For setting the value
% obj = scl_inter(obj,dat)
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: scl_inter.m 1143 2008-02-07... |
github | akhanf/vasst-dev-master | fname.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/private/fname.m | 757 | utf_8 | 183c2721b3e41981c7f22ad2edfd6b0d | function varargout = fname(varargin)
% Format
% For getting the value
% dat = fname(obj)
%
% For setting the value
% obj = fname(obj,dat)
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: fname.m 1143 2008-02-07 19:33:33Z spm
... |
github | akhanf/vasst-dev-master | dim.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/private/dim.m | 867 | utf_8 | 943a833120b5d0d8b266c111a9be8792 | function varargout = dim(varargin)
% Format
% For getting the value
% dat = dim(obj)
%
% For setting the value
% obj = dim(obj,dat)
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: dim.m 1143 2008-02-07 19:33:33Z spm
%
% ni... |
github | akhanf/vasst-dev-master | permission.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/private/permission.m | 947 | utf_8 | a201e1e30098ff93c43a739476a8e1b8 | function varargout = permission(varargin)
% Format
% For getting the value
% dat = permission(obj)
%
% For setting the value
% obj = permission(obj,dat)
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: permission.m 1340 2008-0... |
github | akhanf/vasst-dev-master | dtype.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@file_array/private/dtype.m | 2,334 | utf_8 | c942044c56f516aefe7b7162b031f948 | function varargout = dtype(varargin)
% Format
% For getting the value
% dat = dtype(obj)
%
% For setting the value
% obj = dtype(obj,dat)
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: dtype.m 1143 2008-02-07 19:33:33Z spm
... |
github | akhanf/vasst-dev-master | subsasgn.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@nifti/subsasgn.m | 14,611 | utf_8 | 6610602295787cd2fd81f4af7de6d684 | function obj = subsasgn(obj,subs,varargin)
% Subscript assignment
% See subsref for meaning of fields.
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: subsasgn.m 4136 2010-12-09 22:22:28Z guillaume
%
% niftilib $Id: subsasg... |
github | akhanf/vasst-dev-master | subsref.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@nifti/subsref.m | 8,810 | utf_8 | 2c34f35d86dc57af0e2ca397f84e53e6 | function varargout = subsref(opt,subs)
% Subscript referencing
%
% Fields are:
% dat - a file-array representing the image data
% mat0 - a 9-parameter affine transform (from qform0)
% Note that the mapping is from voxels (where the first
% is considered to be at [1,1,1], to m... |
github | akhanf/vasst-dev-master | create.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@nifti/create.m | 2,031 | utf_8 | 3f57c584ca26f3ffd3a81da54c3da784 | function create(obj,wrt)
% Create a NIFTI-1 file
% FORMAT create(obj)
% This writes out the header information for the nifti object
%
% create(obj,wrt)
% This also writes out an empty image volume if wrt==1
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Cen... |
github | akhanf/vasst-dev-master | getdict.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@nifti/private/getdict.m | 5,296 | utf_8 | f5bf05d2276be8a8ca34ea6357b99af0 | function d = getdict
% Dictionary of NIFTI stuff
% _______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: getdict.m 1143 2008-02-07 19:33:33Z spm
%
% niftilib $Id: getdict.m,v 1.3 2012/03/22 18:36:33 fissell Exp $
%
persistent di... |
github | akhanf/vasst-dev-master | write_extras.m | .m | vasst-dev-master/noddi_mcr/src/niftimatlib-1.2/matlab/@nifti/private/write_extras.m | 951 | utf_8 | bcbfafc0062392efe97a6f395d33da6e | function extras = write_extras(fname,extras)
% Write extra bits of information
%_______________________________________________________________________
% Copyright (C) 2008 Wellcome Trust Centre for Neuroimaging
%
% Id: write_extras.m 1143 2008-02-07 19:33:33Z spm
%
% niftilib $Id: write_extras.m,v 1.3 2012/03/22 18... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | quatrotate.m | .m | RecoveryControl-MATLABSimulator-master/MathOperations/quatrotate.m | 934 | utf_8 | a55bf7c51148bb01ad5db3f17cf27180 | % Rotate a vector r by quaternion q.
% Also works on a matrix r if it is M-by-3
function rout = quatrotate(q,r)
if(size(q,2) ~= 4), error('q must be 1-by-4'); end;
if(size(r,2) ~= 3), error('r must be M-by-3'); end;
% Normalize the quaternion
%qin = q./( sqrt(sum(q.^2,2)) * ones(1,4));
qin = q/norm(q);... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | quat2angle.m | .m | RecoveryControl-MATLABSimulator-master/MathOperations/quat2angle.m | 8,327 | utf_8 | e287fb4e9f003cac37de00070346ab15 | % from MATLAB Aerospace Toolbox
function [r1 r2 r3] = quat2angle( q, varargin )
% QUAT2ANGLE Convert quaternion to rotation angles.
% [R1 R2 R3] = QUAT2ANGLE( Q ) calculates the calculates the set of
% rotation angles, R1, R2, R3, for a given quaternion, Q. Input Q is an
% M-by-4 matrix containing M quaternion... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | angle2quat.m | .m | RecoveryControl-MATLABSimulator-master/MathOperations/angle2quat.m | 6,376 | utf_8 | 0d5d420515d59362d369e2ffab4aec8c | % From MATLAB Aerospace Toolbox
function q = angle2quat( r1, r2, r3, varargin )
% ANGLE2QUAT Convert rotation angles to quaternion.
% Q = ANGLE2QUAT( R1, R2, R3 ) calculates the quaternion, Q, for given,
% R1, R2, R3. R1 is an M array of first rotation angles. R2 is an M
% array of second rotation angles. R... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | getinitworldx.m | .m | RecoveryControl-MATLABSimulator-master/Initialize/getinitworldx.m | 3,471 | utf_8 | 305eeccb5066b2569d138b829d0e8175 | function [ initXPosn, initXVel, timeInit, xAcc ] = getinitworldx( ImpactParams, posnDerivX, IC, givenXAcc )
%getinitworldx.m Find initial X position and velocity required for specific
%initial collision conditions
% Author: Fiona Chui (fiona.chui@mail.mcgill.ca)
% Last Updated: December 12, 2016
% Descripti... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | pdftops.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/pdftops.m | 3,687 | utf_8 | 43c139e49fce63cb78060895bd13137a | function varargout = pdftops(cmd)
%PDFTOPS Calls a local pdftops executable with the input command
%
% Example:
% [status result] = pdftops(cmd)
%
% Attempts to locate a pdftops executable, finally asking the user to
% specify the directory pdftops was installed into. The resulting path is
% stored for futur... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | crop_borders.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/crop_borders.m | 3,791 | utf_8 | 2c8fc83f142f1d5b28b99080556c791e | function [A, vA, vB, bb_rel] = crop_borders(A, bcol, padding)
%CROP_BORDERS Crop the borders of an image or stack of images
%
% [B, vA, vB, bb_rel] = crop_borders(A, bcol, [padding])
%
%IN:
% A - HxWxCxN stack of images.
% bcol - Cx1 background colour vector.
% padding - scalar indicating how much paddi... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | isolate_axes.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/isolate_axes.m | 4,851 | utf_8 | 611d9727e84ad6ba76dcb3543434d0ce | function fh = isolate_axes(ah, vis)
%ISOLATE_AXES Isolate the specified axes in a figure on their own
%
% Examples:
% fh = isolate_axes(ah)
% fh = isolate_axes(ah, vis)
%
% This function will create a new figure containing the axes/uipanels
% specified, and also their associated legends and colorbars. The o... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | im2gif.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/im2gif.m | 6,234 | utf_8 | 8ee74d7d94e524410788276aa41dd5f1 | %IM2GIF Convert a multiframe image to an animated GIF file
%
% Examples:
% im2gif infile
% im2gif infile outfile
% im2gif(A, outfile)
% im2gif(..., '-nocrop')
% im2gif(..., '-nodither')
% im2gif(..., '-ncolors', n)
% im2gif(..., '-loops', n)
% im2gif(..., '-delay', n)
%
% This function c... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | read_write_entire_textfile.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/read_write_entire_textfile.m | 961 | utf_8 | 775aa1f538c76516c7fb406a4f129320 | %READ_WRITE_ENTIRE_TEXTFILE Read or write a whole text file to/from memory
%
% Read or write an entire text file to/from memory, without leaving the
% file open if an error occurs.
%
% Reading:
% fstrm = read_write_entire_textfile(fname)
% Writing:
% read_write_entire_textfile(fname, fstrm)
%
%IN:
% fn... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | pdf2eps.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/pdf2eps.m | 1,522 | utf_8 | 4c8f0603619234278ed413670d24bdb6 | %PDF2EPS Convert a pdf file to eps format using pdftops
%
% Examples:
% pdf2eps source dest
%
% This function converts a pdf file to eps format.
%
% This function requires that you have pdftops, from the Xpdf suite of
% functions, installed on your system. This can be downloaded from:
% http://www.foolabs.c... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | print2array.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/print2array.m | 9,613 | utf_8 | e398a6296734121e6e1983a45298549a | function [A, bcol] = print2array(fig, res, renderer, gs_options)
%PRINT2ARRAY Exports a figure to an image array
%
% Examples:
% A = print2array
% A = print2array(figure_handle)
% A = print2array(figure_handle, resolution)
% A = print2array(figure_handle, resolution, renderer)
% A = print2array(figur... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | append_pdfs.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/append_pdfs.m | 2,759 | utf_8 | 9b52be41aff48bea6f27992396900640 | %APPEND_PDFS Appends/concatenates multiple PDF files
%
% Example:
% append_pdfs(output, input1, input2, ...)
% append_pdfs(output, input_list{:})
% append_pdfs test.pdf temp1.pdf temp2.pdf
%
% This function appends multiple PDF files to an existing PDF file, or
% concatenates them into a PDF file if the o... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | using_hg2.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/using_hg2.m | 1,037 | utf_8 | 3303caab5694b040103ccb6b689387bf | %USING_HG2 Determine if the HG2 graphics engine is used
%
% tf = using_hg2(fig)
%
%IN:
% fig - handle to the figure in question.
%
%OUT:
% tf - boolean indicating whether the HG2 graphics engine is being used
% (true) or not (false).
% 19/06/2015 - Suppress warning in R2015b; cache result for i... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | eps2pdf.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/eps2pdf.m | 7,840 | utf_8 | 456ac77253151354fa668b4947f74cd1 | function eps2pdf(source, dest, crop, append, gray, quality, gs_options)
%EPS2PDF Convert an eps file to pdf format using ghostscript
%
% Examples:
% eps2pdf source dest
% eps2pdf(source, dest, crop)
% eps2pdf(source, dest, crop, append)
% eps2pdf(source, dest, crop, append, gray)
% eps2pdf(source, de... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | export_fig.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/export_fig.m | 55,209 | utf_8 | ced5f0dc3aaa8384801c6c968223e087 | function [imageData, alpha] = export_fig(varargin)
%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 ... -transpare... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | ghostscript.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/ghostscript.m | 7,683 | utf_8 | 4def5873a1621e793bd59aaa23f3fc25 | function varargout = ghostscript(cmd)
%GHOSTSCRIPT Calls a local GhostScript executable with the input command
%
% Example:
% [status result] = ghostscript(cmd)
%
% Attempts to locate a ghostscript executable, finally asking the user to
% specify the directory ghostcript was installed into. The resulting path... |
github | McGill-AML/RecoveryControl-MATLABSimulator-master | fix_lines.m | .m | RecoveryControl-MATLABSimulator-master/External/altmany-export_fig-d966721/fix_lines.m | 6,441 | utf_8 | ffda929ebad8144b1e72d528fa5d9460 | %FIX_LINES Improves the line style of eps files generated by print
%
% Examples:
% fix_lines fname
% fix_lines fname fname2
% fstrm_out = fixlines(fstrm_in)
%
% This function improves the style of lines in eps files generated by
% MATLAB's print function, making them more similar to those seen on
% scre... |
github | daniel-koehn/DENISE-Black-Edition-master | GetSegyTraceData.m | .m | DENISE-Black-Edition-master/par/visu/segymat/GetSegyTraceData.m | 2,758 | utf_8 | ebf8e7cb00aaaa9211b8d1fa2ef5957e | % GetSegyTraceData : Get Segy trace data if filehandle
%
% Call :
%
% tracedata=GetSegyTraceData(segyid,ns,SegyHeader,SkipData
%
%
% (C) 2001-2004 Thomas Mejer Hansen, tmh@gfy.ku.dk/thomas@cultpenguin.com
%
% This program is free software; you can redistribute it and/or modify
% it under the terms of the GNU... |
github | daniel-koehn/DENISE-Black-Edition-master | GetSegyTraceHeader.m | .m | DENISE-Black-Edition-master/par/visu/segymat/GetSegyTraceHeader.m | 8,830 | utf_8 | 330af92104ce4a2df035bef2bc573e7f | % GetSegyTraceHeader : Reads a seg y trace, data and header
%
% [SegyTraceHeader]=GetSegyTraceHeader(segyid,TraceStart,DataFormat,ns);
%
%
% (C) 2001-2004 Thomas Mejer Hansen, thomas.mejer.hansen@cultpenguin.com
%
% Revisions:
% 07/2008 Kristian Stormark (<kristian.stormark@gmail.com>) : Reduce the
% number o... |
github | daniel-koehn/DENISE-Black-Edition-master | ReadSu.m | .m | DENISE-Black-Edition-master/par/visu/segymat/ReadSu.m | 9,155 | utf_8 | 851997f3d9f738272cc5a6cf95b6001a | % ReadSu : Reads a SU formatted file (Seismic Unix)
%
% Call :
% [Data,SuTraceHeaders,SuHeader]=ReadSu(filename);
%
% To read in big endian format (default):
% [Data,SuTraceHeaders,SuHeader]=ReadSu(filename,'endian','b');
% To read in little endian format :
% [Data,SuTraceHeaders,SuHeader]=ReadSu(filename,'endian','l')... |
github | daniel-koehn/DENISE-Black-Edition-master | SegymatVerbose.m | .m | DENISE-Black-Edition-master/par/visu/segymat/SegymatVerbose.m | 1,283 | utf_8 | 91cbd5d1f9f24c536b01898b26f34abc | % SegymatVerbose : Writes out verbose information to the screen
%
%
% Call :
% SegymatVerbose(text,verboselevel)
% prints out 'text' to screen if verboselevel is higher than threshold
% set in m-file.
%
%
% (C) 2001-2004, Thomas Mejer Hansen, tmh@gfy.ku.dk/thomas@cultpenguin.com
%
% This program is free sof... |
github | daniel-koehn/DENISE-Black-Edition-master | GetSegyHeaderBasics.m | .m | DENISE-Black-Edition-master/par/visu/segymat/GetSegyHeaderBasics.m | 9,796 | utf_8 | 301b05e3751a42ada175b3acffe840b1 | % GetSegyHeaderBasics : Default Segy Header Header settings
%
% Call :
% Rev=GetSegyHeaderBasics
%
%
%
% (C) 2001-2004, Thomas Mejer Hansen, tmh@gfy.ku.dk/thomas@cultpenguin.com
%
% This program is free software; you can redistribute it and/or modify
% it under the terms of the GNU General Public License as pub... |
github | kakearney/ncreads-pkg-master | ncstruct.m | .m | ncreads-pkg-master/ncreads/ncstruct.m | 7,469 | utf_8 | e114e2221315f8c8dad6dafb8636c081 | function Data = ncstruct(files, varargin)
%NCSTRUCT Read variables from a netcdf file or files
%
% Data = ncstruct(files, var1, var2, ...)
% Data = ncstruct(files, Scs, var1, var2, ...)
%
% This function reads multiple variables from a netCDF file or files into a
% structure array. It also provides a useful wrapper to... |
github | MIT-LCP/ds-review-master | ReviewDischargeSummaries.m | .m | ds-review-master/ReviewDischargeSummaries.m | 21,607 | utf_8 | 215dc90029eb772e7930c95de728eecc | function varargout = ReviewDischargeSummaries(varargin)
% REVIEWDISCHARGESUMMARIES MATLAB code for ReviewDischargeSummaries.fig
% REVIEWDISCHARGESUMMARIES, by itself, creates a new REVIEWDISCHARGESUMMARIES or raises the existing
% singleton*.
%
% H = REVIEWDISCHARGESUMMARIES returns the handle to a new R... |
github | micahjsmith/bls-matlab-master | fetch.m | .m | bls-matlab-master/@bls/fetch.m | 4,639 | utf_8 | 06bdee216c047a8d00ed6a69d900bd26 | function d = fetch(c,s,varargin)
% FETCH Request data from BLS.
% D = FETCH(C,S) returns data from the BLS API for a given series or cell
% array of series, S, and connection handle, C. Defaults to last 10 years
% of data.
%
% D = FETCH(C,S,D1) returns data for the year D1 to present.
%
% D = FETCH(C,S,D1,D2... |
github | franzsetti/GCFF-master | ff_evalgroups.m | .m | GCFF-master/ff_evalgroups.m | 7,848 | utf_8 | 08ccd09f51d044d064cea4acc0c5a0a3 | % -----------------------------------------
% Graph-Cuts for F-Formation (GCFF)
% 2015 - University of Verona
% Written by Francesco Setti
% -----------------------------------------
%
% EVALGROUPS computes precision and recall scores, as well as the number of
% true positives, false positives and false negatives, give... |
github | franzsetti/GCFF-master | gc.m | .m | GCFF-master/gc.m | 3,134 | utf_8 | 4879e95ee235a51a27ff7cb661d92513 | function seg = gc( f, stride, MDL_in)
% Runs graph-cuts
locs = find_locs( f, stride ) ;
unary = init( locs, f, MDL_in ) ;
neigh = zeros(size(f,1),1) ;
weight = zeros(size(f,1),1) ;
seg = (0:size(f,1)-1)' ;
segold = zeros(length(seg),1) ;
MAX_ITER = 10 ;
numiter = 1 ;
% close all,
while ~isequal(seg,segold) && num... |
github | franzsetti/GCFF-master | ff_plot_person_tv.m | .m | GCFF-master/ff_plot_person_tv.m | 1,468 | utf_8 | 0b51c8a99ae56cd145139163eff192a9 | % -----------------------------------------
% Graph-Cuts for F-Formation (GCFF)
% 2015 - University of Verona
% Written by Francesco Setti
% -----------------------------------------
%
% This function plots a person symbol from top view.
%
function ff_plot_person_tv( xx_feat, yy_feat, alpha_feat, col, scale)
if ~ex... |
github | franzsetti/GCFF-master | ff_gengrid.m | .m | GCFF-master/ff_gengrid.m | 1,275 | utf_8 | b9a0c64796bf92806505fd69686522e1 | % -----------------------------------------
% Graph-Cuts for F-Formation (GCFF)
% 2015 - University of Verona
% Written by Francesco Setti
% -----------------------------------------
%
% This function generates a grid for Hough voting with a quantization
% 'quant'.
%
function [votegrid, votegrid_pos] = ff_gengrid( fea... |
github | franzsetti/GCFF-master | ff_deletesingletons.m | .m | GCFF-master/ff_deletesingletons.m | 518 | utf_8 | 411e6398ad61b0d85a5343c9ff393568 | % -----------------------------------------
% Graph-Cuts for F-Formation (GCFF)
% 2015 - University of Verona
% Written by Francesco Setti
% -----------------------------------------
%
% This function deletes all the groups formed by a single individual.
%
function gr_out = ff_deletesingletons( gr_in )
% Delete all ... |
github | jeremiedecock/snippets-master | function_with_param.m | .m | snippets-master/octave/function_with_param.m | 1,322 | utf_8 | 1f0a96a23ba06de2c8f1b9362107e19d | #!/usr/bin/octave -q
% Copyright (c) 2014 Jérémie DECOCK (http://www.jdhp.org)
% Permission is hereby granted, free of charge, to any person obtaining a copy
% of this software and associated documentation files (the "Software"), to deal
% in the Software without restriction, including without limitation the rights
%... |
github | jeremiedecock/snippets-master | print_functions_and_variables_in_memory.m | .m | snippets-master/octave/print_functions_and_variables_in_memory.m | 1,370 | utf_8 | 6d0af1cc583fb92a88c4e305e6ba298e | #!/usr/bin/octave -q
% Copyright (c) 2014 Jérémie DECOCK (http://www.jdhp.org)
% Permission is hereby granted, free of charge, to any person obtaining a copy
% of this software and associated documentation files (the "Software"), to deal
% in the Software without restriction, including without limitation the rights
%... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.