Open main menu

Changes

SPARKY list

1,103 bytes added, 09:46, 11 October 2013
</source>
The '''N''' should be standing first, and the '''w1''' should be the corresponding ppm for nitrogen.
 
== sparky_shift1_col.sh ==
<source lang="bash">
#!/bin/tcsh -f -e
set PEAKS=$1
set PEAKSTEMP=${PEAKS}.temp
set PEAKSNEW=${PEAKS}.shift
#awk '{print $1, $2, $3}' $PEAKS > $PEAKSTEMP
cp -f $PEAKS $PEAKSTEMP
set ASSIGNS=`awk '$2 ~ /^[0-9]/ {print $0}' $PEAKSTEMP`
#set ASSIGNS=`awk '{print $1, $2, $3}' $PEAKSTEMP`
set TJECK1=`echo $ASSIGNS[1] | rev | cut -c1`
set TJECK2=`echo $ASSIGNS[1] | rev | cut -c2`
set TJECK12=`echo $ASSIGNS[1] | rev | cut -c1-2`
if ( $TJECK2 == 'H' && $TJECK12 == 'NH' ) then
else if ( $TJECK1 == 'N') then
sed -i "s/HN/XX/" $PEAKSTEMP
sed -i "s/N /HN /" $PEAKSTEMP
sed -i "s/XX/N/" $PEAKSTEMP
else
echo "Whoops. Something wrong, I exit. Check your peak list"
exit
endif
 
set C2=`expr $ASSIGNS[2]`
set C3=`expr $ASSIGNS[3]`
set C2N=`echo "$C2 > 50" | bc`
set C2HN=`echo "$C2 < 15" | bc`
set C3N=`echo "$C3 > 50" | bc`
set C3HN=`echo "$C3 < 15" | bc`
if ($C2N == 1 && $C3HN == 1) then
awk '{print $1,$2,$3}' $PEAKSTEMP > $PEAKSNEW
else if ($C3N == 1 && $C2HN == 1) then
awk '{print $1,$3,$2}' $PEAKSTEMP > $PEAKSNEW
endif
rm $PEAKSTEMP
</source>
== See also ==
[[Category:Peak_lists]]
[[Category:Software]]
Trusted, Bureaucrats
1,382

edits