File: README

package info (click to toggle)
aevol 5.0%2Bds-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 2,536 kB
  • sloc: cpp: 25,999; ansic: 997; makefile: 248; sh: 91
file content (224 lines) | stat: -rw-r--r-- 6,661 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
###############################################################################
#                         The Workflow example
###############################################################################
# This is the workflow example. It provides an example of one of the many
# different workflows that can be used for experiments with Aevol.
#
# The main idea underlying this workflow is to parallel wet lab experiments,
# which are conducted on evolved organisms.
# To use already evolved organisms for Aevol experiments, one can either use
# an evolved genome provided by the community or evolve his own.
# This example does the latter (more complete) case.
#
#
###################
# RECOMMENDATIONS #
###################
#
# It is strongly recommended you read the corresponding section in the user
# manual while following this example since it contains an explanation for
# each step of the example.
#
# The following set of commands should work as is if you have installed aevol
# with make install, which is recommended.
#
# If you haven't installed aevol, you will nedd to either add the binaries'
# locations in your PATH or to specify where to find them at each step.
# They should be in <aevol_dir>/src for the 4 main executables
# and in <aevol_dir>/src/post_treatments for the rest, <aevol_dir> being the
# main aevol directory you have downloaded.
# E.g. if your <aevol_dir> is /home/login/aevol, then the command
# aevol_run -n 5000 will become /home/login/aevol/src/aevol_run -n 5000
# and ae_misc_lineage -e 10000 will become
# /home/login/aevol/src/post_treatments/ae_misc_lineage -e 10000
#
###############################################################################


# ========== Wild-Type generation ==========
#
#mkdir wild_type
cd wild_type
aevol_create
aevol_run -n 5000 -p -1
# "-p -1" means you ask aevol to be run on n threads, with n
# being determined by your system's settings


# ========== Experimental setup ==========
#
# Propagate the experiment, meaning prepare directories for different
# runs starting from the wild type
# By default, the random generator states are modified so that you
# don't end up with the exact same simulation repeated several times
# but rather different repetitions with the same set of parameters
#
outdirsA="line01 line02 line03 line04 line05"
outdirsB="line06 line07 line08 line09 line10"
outdirsC="line11 line12 line13 line14 line15"
for mydir in $outdirsA $outdirsB $outdirsC
do
  aevol_propagate -o ../$mydir
done

# Go back to the workflow example directory
cd ..

# For each experiment, create a file with the parameters to change
echo "# New environment
ENV_GAUSSIAN  0.5   0.2   0.05
ENV_GAUSSIAN  0.5   0.4   0.05
ENV_GAUSSIAN  0.5   0.8   0.05
ENV_VARIATION none
# New rearrangement rates
DUPLICATION_RATE    1e-4
DELETION_RATE       1e-4
TRANSLOCATION_RATE  1e-4
INVERSION_RATE      1e-4" > newparam-groupA.in

echo "# New environment
ENV_GAUSSIAN  0.5   0.2   0.05
ENV_GAUSSIAN  0.5   0.4   0.05
ENV_GAUSSIAN  0.5   0.8   0.05
ENV_VARIATION none
# New rearrangement rates
DUPLICATION_RATE    1e-6
DELETION_RATE       1e-6
TRANSLOCATION_RATE  1e-6
INVERSION_RATE      1e-6" > newparam-groupB.in

echo "# New environment
ENV_GAUSSIAN  0.5   0.2   0.05
ENV_GAUSSIAN  0.5   0.4   0.05
ENV_GAUSSIAN  0.5   0.8   0.05
ENV_VARIATION none" > newparam-groupC.in


# Apply these modifications
#
for mydir in $outdirsA
do
   cd $mydir
   aevol_modify -f ../newparam-groupA.in
   cd ..
done

for mydir in $outdirsB
do
  cd $mydir
  aevol_modify -f ../newparam-groupB.in
  cd ..
done

for mydir in $outdirsC
do
  cd $mydir
  aevol_modify -f ../newparam-groupC.in
  cd ..
done




# ========== Run the simulations ==========
#
for mydir in $outdirsA $outdirsB $outdirsC
do
  cd $mydir
  aevol_run -e 20000 -p -1
  cd ..
done

# You can stop any simulation at any time and resume it from where you've
# stopped it with the exact same command (from within the same directory)
# e.g.
# cd line01
# aevol_run -e 20000 -p -1



# ========== Analyse the outcome ==========
#
# A set of post-treatment tools is available to help analyse the outcome.
# 

# ---------- aevol_misc_view ----------
#
# The simplest miscellaneous tool is view. It allows one to
# visualize a simulation at a given timestep using the exact
# same graphical outputs used in aevol_run.
# However, since it relies on graphics, it is only available when aevol is
# compiled with x enabled (which is the default).
#
#cd line01
#aevol_misc_view
#cd ..


# ---------- aevol_misc_create_eps ----------
#
# Similarly, one can obtain eps outputs for a given generation with the 
# create_eps tool. Files will be outputted in eps_files_xxxxxx (with 
# xxxxxx the generation number)
#
for mydir in $outdirsA $outdirsB $outdirsC
do
  cd $mydir
  aevol_misc_create_eps &
  cd ..
done


# ---------- aevol_misc_robustness ----------
#
# The robustness tool computes the replication statistics of all the 
# individuals of a given generation, like the proportion of neutral, beneficial, 
# deleterious offsprings. This is done by simulating nbchildren replications 
# for each individual (1000 replications by default), with its mutation, 
# rearrangement and transfer rates. Depending on those rates and genome 
# size, there can be several mutations per replication. Those global statistics 
# are written in stat/robustness_numgener.out, with one line per individual
# in the specified generation.
# The program also outputs detailed statistics for one of the individuals (the 
# best one by default). The detailed statistics for this individual are written in
# stats/replication_numgener.out, with one line per simulated child of this 
# particular individual.
#
for mydir in $outdirsA $outdirsB $outdirsC
do
   cd $mydir
   aevol_misc_robustness &
   cd ..
done


# ---------- aevol_misc_lineage ----------
#
# One can reconstruct the lineage of an evolved individual.
# This will generate a lineage file whose name will look like
# lineage-b000000-e010000-i999-r1000.ae containing the complete mutational
# history of a given individual of a given generation.
# This file can then be used as the input for subsequent post-treatments.
#
for mydir in $outdirsA $outdirsB $outdirsC
do
   cd $mydir
   aevol_misc_lineage
   cd ..
done


# ---------- aevol_misc_ancstats ----------
#
# Statistics of a lineage can be obtained with this tool.
# The generated output is in stats/ancstats/
#
# The option -M adds the list of mutational events that occurred
# on the lineage as an additional output (in stats/).
#
for mydir in $outdirsA $outdirsB $outdirsC
do
   cd $mydir
   aevol_misc_ancestor_stats lineage-*.ae -M &
   cd ..
done