source: trunk/UTIL/xmgrace-remplimat/exemples-tri.sh @ 504

Last change on this file since 504 was 4, checked in by dumas, 10 years ago

initial import GRISLI trunk

File size: 1.4 KB
Line 
1# quelques scripts de tri
2
3# color  0 "white"     color  1 "black"    color   2  "red"    color  3    "green"      color 4 "blue"
4# color  5 "yellow"    color  6 "brown"    color   7  "grey"   color  8    "violet"     color 9 "cyan"
5# color 10 "magenta"   color 11 "orange"   color  12  "indigo" color 13    "maroon"
6# color 14 "turquoise"                     color  15   "green4"
7
8
9Bmeshelf
10
11#1 2  3      4                 5         6           7           8          9 
12#i,j,grd,typeshelf(i,j),   bmelt(i,j),bmgrz(i,j),bmshelf(i,j),hdot(i,j),dist_talu(i,j)
13#awk '{ if ($8 != 0 && $3 != 0) { if ($7 == 0) print $1,$2,"2",$3; else if ($7 > 0) print $1,$2,"3",$3; else if ($7 <0)  print $1,$2,"4",$3 }  }' graph-Mat > graph-i1j1
14
15
16# $4 est l'ice shelf $3 est grdline(1) ou pas (0)
17
18awk '{ if ($4 == 1 && $3 == 0)  print $3,$4,$5,$5+$8}' bmelt-test |awk '{Som=$4+Som; nb=nb+1; print $3,$4,Som,nb,Som/nb}' > toto.dat
19
20
21
22
23#  la somme d'une colonne
24
25#awk '{A=$1+A; print A}' test
26
27# Pour remplimat
28
29
30# vert : surdiagonales , rouge : diagonales , bleu sous-diagonales. Seulement pour les points ou Tu!=0
31
32awk '{ if ($8 != 0 && $3 != 0) { if ($7 == 0) print $1,$2,"2",$3; else if ($7 > 0) print $1,$2,"3",$3; else if ($7 <0)  print $1,$2,"4",$3 }  }' graph-Mat > graph-i1j1
33
34
35
36# Pour tagger une ligne de tuij, enlever les noeuds imx=0
37
38awk '{ if ($5 == 71)   print $1,$2,"2",$3; else if ($8 !=0) print $1,$2,"4",$3   }' graph-Mat > graph-i1j1
Note: See TracBrowser for help on using the repository browser.