projects
/
thesis.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
311f00e
)
src/figures/cantilever-data/get_v_dep.sh: print -> print()
author
W. Trevor King
<wking@tremily.us>
Wed, 17 Apr 2013 21:57:56 +0000
(17:57 -0400)
committer
W. Trevor King
<wking@tremily.us>
Wed, 17 Apr 2013 21:57:56 +0000
(17:57 -0400)
Fix embedded Python syntax to avoid:
cd .. && ./get_v_dep.sh
File "<string>", line 1
print '%.2f' % 131.
97793902439034
^
SyntaxError: invalid syntax
src/figures/cantilever-data/get_v_dep.sh
patch
|
blob
|
history
diff --git
a/src/figures/cantilever-data/get_v_dep.sh
b/src/figures/cantilever-data/get_v_dep.sh
index e2153eceb87392842117076ecfdb6da1cd89df11..bf8972fc648d5a96ac2c77b39a7989c840589b26 100755
(executable)
--- a/
src/figures/cantilever-data/get_v_dep.sh
+++ b/
src/figures/cantilever-data/get_v_dep.sh
@@
-9,7
+9,7
@@
AVGFILE='./data/averaged-data'
while read LINE
do
Kprecise=`echo "$LINE" | sed 's/.*= \([0-9.]*\) +.*/\1/'`
- K=`python -c "print
'%.2f' % $Kprecise
"`
+ K=`python -c "print
('{:.2f}'.format($Kprecise))
"`
FILE="v-dep.d/v_dep_$K"
echo "clearing $FILE"
> "$FILE.dat"