This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
%% transforms | |
% transform into fsl coordinates (CT) | |
fslpos = elec.elecpos; | |
fslpos(:,4) = 1; | |
fslpos = (img_ct.transform \ fslpos')'; | |
if img_ct.hdr.x_r == 1 | |
fslpos(:,1) = img_ct.dim(1) - fslpos(:,1); | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Usage dicom_to_nifti_anonymize [source dir] [dest dir] [participant ID] | |
if [[ $# -lt 2 ]]; then | |
DEST=$1 | |
else | |
# make the directory if it doesn't exist | |
if [ ! -d $2 ]; then | |
mkdir $2 | |
fi |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Simeon Wong | |
if [ -d $1 ] | |
then | |
# make destination directory | |
mkdir $2 | |
SRCBASE=$(basename $1 .ds) |
NewerOlder