Skip to content

Instantly share code, notes, and snippets.

View stowler's full-sized avatar

Stephen Towler stowler

View GitHub Profile
@stowler
stowler / afniSwitchToRepo.sh
Created August 12, 2013 16:25
afniSwitchToRepo.sh - switch the user back to the neurodebian repository version of AFNI
#!/bin/bash
# afniSwitchToRepo.sh
#
# A script to switch the user back to the neurodebian repo version of AFNI from a
# local alternative install (e.g., /opt/abin). Works in combination with
# afniSwitchFromRepo.sh
echo ""
echo "Switching back to the repo version of AFNI:"
@stowler
stowler / afniSwitchFromRepo.sh
Last active December 20, 2015 23:28
afniSwitchFromRepo.sh - temporarily switch from the neurodebian repo version of AFNI to a local alternative
#!/bin/bash
# afniSwitchFromRepo.sh
#
# A script to tempoarily switch the user from the neurodebian repo version of
# AFNI to a local alternative install (e.g., /opt/abin). Works in combination
# with afniSwitchToRepo.sh
# Specify the parent directory of alternative AFNI's binaries:
@stowler
stowler / qcExample-noceraCDA2-fmri-categoryMemberGeneration.sh
Created July 24, 2013 22:02
This is a short script to illustrate quality control (qc) and DICOM to nifti conversion of fmri series.
#!/bin/bash
#
# created: 20130724 by stowler@gmail.com
# edited: 20130724 by stowler@gmail.com
#
# This is a short script to illustrate quality control (qc) and conversion of
# Nocera CDA2 DICOM data.
# - It is currently designed for FMRI runs from a single session of scanning
# (i.e., one trip to the scanner, or one "study").
# - It is not written to accept commandline arguments. Instead, make a copy of
@stowler
stowler / win7-vmware2virtualbox.diff
Created July 17, 2013 18:01
diff of ovf changes needed for today's successful vmware -> virtualbox migration of windows 7 VM
macula:OVF copy stowler-local$ diff -u Windows\ 7x86\ DanOrig.ovf Windows\ 7x86.ovf
--- Windows 7x86 DanOrig.ovf 2013-07-16 17:15:35.000000000 -0400
+++ Windows 7x86.ovf 2013-07-17 12:10:02.000000000 -0400
@@ -54,14 +54,6 @@
<vmw:Config ovf:required="false" vmw:key="ehciEnabled" vmw:value="true"/>
</Item>
<Item>
- <rasd:Address>0</rasd:Address>
- <rasd:Description>SCSI Controller</rasd:Description>
- <rasd:ElementName>scsiController0</rasd:ElementName>
@stowler
stowler / harold_voxPropNeg_thresh.Rsq95pct.md
Last active December 18, 2015 05:09
harold negative bold comparison for Friday review

Mean proportion of negative bold voxels is greater in young group than oldOld group.

NB: polling only suprathreshold voxels where rsq > (.95 * participantRsqMax)

  1. Significant (p=0.03) one-way ANOVA comparing group means of voxPropNeg:

 Df Sum Sq Mean Sq F value Pr(>F) 
@stowler
stowler / setupNeuroimagingEnvironment.md
Last active December 17, 2015 16:09
consolidating my setup notes for inclusion in a repo

setupNeuroimagingEnvironment.md

All of my scripts and documentation assume that these neuroimaging resources have been installed. For each package I cover the three computing environments I currently use:

  • OS X Mountain Lion + MacPorts
  • Neurodebian on Ubuntu 12.04 on 64-bit processors
  • Neurodebian VM, running Debian 7.0 wheezy 32-bit on VirtualBox

Software covered:

@stowler
stowler / aTestLoopForTraining.sh
Created May 15, 2013 18:59
scratch pad script from early training with Jen
#!/bin/bash
# scratch pad script for inital training with Jen
# stowler@gmail.com
# this is a short script to loop QA for Joe's data
seriesList="4 5 6 7 8 9"
parentDicomDir=~/Downloads/Fiji.app/DICOMSTORE/CDA101/MR/20130429/135538.453000/1
bxhDir=~/Downloads/bxh_xcede_tools-1.10.7-lsb30.x86_64/bin/
@stowler
stowler / installNotes-neuroImagingSoftware-notaScriptDoNotRun.sh
Last active December 17, 2015 03:38
my neuroimaging software install notes for mac OS X mountain lion and ubuntu 12.04 (mostly with neurodebian)
# stowler@gmail.com
# updated: 20130508
#
# These are my personal notes about installing neuroimaging software
# on Mac OS X Mountain/Lion and Ubuntu 12.04 (mostly neurodebian).
#
# Some of this can be pasted into install scripts or the bash prompt.
# Be careful: this is an active working document, probably filled with errors.
#
# software covered:
@stowler
stowler / workAround-installBxhOnMountainLion.sh
Last active December 17, 2015 01:09
work-around for bxh/imagemagick problem on mountain/lion
#!/bin/bash
#
# workAround-installBxhOnMountainLion.sh
# stowler@gmail.com
#
# As of May 2013, the shipping version of BXH/XCEDE tools for OS X includes broken imagemagick:
#
# $ bin/fmriqa_generate.pl ~/test.bxh ~/testQA
# Trying int16 data type (instead of input uint16 datatype).
# Checking for overflow...
@stowler
stowler / errors-bxhInternalImagemagickOnML10.8.3.txt
Created May 6, 2013 00:27
bxh fmriqa_generate.pl seems to have problems on mountain lion. At least in the current nitrc version (bxh_xcede_tools-1.10.7-MacOSX.i686.tgz)
$ bin/fmriqa_generate.pl ~/test.bxh ~/testQA
Trying int16 data type (instead of input uint16 datatype).
Checking for overflow...
dyld: Library not loaded: /System/Library/Frameworks/OpenCL.framework/Versions/A/Libraries/libclparser.dylib
Referenced from: /Users/stowler/Downloads/bxh/bin/montage
Reason: image not found
dyld: Library not loaded: /System/Library/Frameworks/OpenCL.framework/Versions/A/Libraries/libclparser.dylib
Referenced from: /Users/stowler/Downloads/bxh/bin/convert
Reason: image not found
...(snip)...