Commit b7f92997 authored by Bo-Chun Chen's avatar Bo-Chun Chen
Browse files

Update fsqc.sh

Create an entry in index.html only if tksurfer execute successfully
parent 742c24a2
......@@ -4,17 +4,6 @@ echo "<html>" > index.html
echo "<table>" >> index.html
for sub in $(ls ${SUBJECTS_DIR});
do
echo "<tr>" >> index.html
echo "<td><a href=\"file:"$sub".lh.lat.hr.png\"><img width=\"300\" src=\""$sub".lh.lat.hr.png\"></a></td>" >> index.html
echo "<td><a href=\"file:"$sub".lh.med.hr.png\"><img width=\"300\" src=\""$sub".lh.med.hr.png\"></a></td>" >> index.html
echo "<td><a href=\"file:"$sub".rh.lat.hr.png\"><img width=\"300\" src=\""$sub".rh.lat.hr.png\"></a></td>" >> index.html
echo "<td><a href=\"file:"$sub".rh.med.hr.png\"><img width=\"300\" src=\""$sub".rh.med.hr.png\"></a></td>" >> index.html
echo "</tr>" >> index.html
echo "<tr>" >> index.html
echo "<td colspan=4><center>"$sub"</center><br></td>" >> index.html
echo "</tr>" >> index.html
echo "labl_import_annotation \"aparc.annot\"" > tmp.tcl
echo "scale_brain 1.35" >>tmp.tcl
echo "redraw" >>tmp.tcl
......@@ -33,7 +22,17 @@ do
echo "redraw" >>tmp.tcl
echo "save_tiff "$sub".rh.med.hr.tif" >>tmp.tcl
echo "exit 0" >>tmp.tcl
tksurfer $sub rh pial -tcl tmp.tcl
tksurfer $sub rh pial -tcl tmp.tcl && {
echo "<tr>" >> index.html
echo "<td><a href=\"file:"$sub".lh.lat.hr.png\"><img width=\"300\" src=\""$sub".lh.lat.hr.png\"></a></td>" >> index.html
echo "<td><a href=\"file:"$sub".lh.med.hr.png\"><img width=\"300\" src=\""$sub".lh.med.hr.png\"></a></td>" >> index.html
echo "<td><a href=\"file:"$sub".rh.lat.hr.png\"><img width=\"300\" src=\""$sub".rh.lat.hr.png\"></a></td>" >> index.html
echo "<td><a href=\"file:"$sub".rh.med.hr.png\"><img width=\"300\" src=\""$sub".rh.med.hr.png\"></a></td>" >> index.html
echo "</tr>" >> index.html
echo "<tr>" >> index.html
echo "<td colspan=4><center>"$sub"</center><br></td>" >> index.html
echo "</tr>" >> index.html
}
rm tmp.tcl
done;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment