Messages from list : cormas@cirad.fr

Choose a topic among the following archives :

RE : RE : drawing of lots

New Message Reply Date view Thread view Subject view Author view

Subject: RE : RE : drawing of lots
From: Romain Lorrilliere (lorrilliere.romain@neuf.fr)
Date: Tue Jun 07 2005 - 09:38:47 CEST

Thanks for your quick answer, but I have a new ask.
 
In my grey heron colonisation model, I would like to average model
outcomes over several simulations (Monte Carlo). Does anyone know how to
do that in Cormas.
 
If it's not possible to get the average results directly in Cormas. I
would like get a file ascii of state value for each cell after each
simulation. But the software does not export any data.
 
Thank you in advance!
 
Romain
________________________________________________
 
Lorrilliere Romain
 
Adresse postale : 3 allée Charles Lindbergh
                            44800 Saint Herblain
 
Tel mobil : 06 81 70 90 70
Tel : 02 40 63 22 23
 
Email : lorrilliere.romain@neuf.fr
 
-----Message d'origine-----
De : owner-cormas@cirad.cirad.fr [mailto:owner-cormas@cirad.cirad.fr] De
la part de Christophe Le Page
Envoyé : mardi 24 mai 2005 14:55
À : 'Romain Lorrilliere'; cormas@cirad.fr
Objet : RE : drawing of lots
 
 
Bonjour Romain,
 
You need to write two functions, the last one being the main one:
 
probaPoisson: mu value: i
     ^(mu ** i * mu negated exp / i factorial) asFloat
 
getValueFromPoisson: mu
| randomValue i found cumul |
    randomValue := self random.
     i := -1.
     found := false.
     cumul := 0.
     [found not] whileTrue:
           [i := i + 1.
           cumul := cumul + (self probaPoisson: mu value: i).
           found := randomValue < cumul].
     ^i
 
 
Let me know if this is what you needed.
Please send us your manuscript by the end of your master thesis, I'll
add it to the list of students' contributions. I'm quite sure your
Cormas model will greatly interest some people around !
 
Clp
 
-----Message d'origine-----
De : owner-cormas@cirad.fr [mailto:owner-cormas@cirad.fr] De la part de
Romain Lorrilliere
Envoyé : lundi 23 mai 2005 16:38
À : cormas@cirad.fr
Objet : drawing of lots
Dear members,
 
I’m modelling the dynamic population of the grey Heron and i d like to
define some t to t+1 transitions in the status of cells according to a
random drawing from a Poisson distribution.
Does anyone have an idea on how i could achieve that?
 
Thinks
 
Romain
________________________________________________
 
Lorrilliere Romain
 
Etudiant Master 2 Muséum National d'Histoire Naturelle
  Evolution, Patrimoine Naturel et Sociétés
     Specialité :Systèmatique, Evolution & Paléontologie
         Orientation : Informatique appliquée à la biodiversité
 
Adresse postale : 3 allée Charles Lindbergh
                            44800 Saint Herblain
 
Tel mobil : 06 81 70 90 70
Tel : 02 40 63 22 23
 
Email : lorrilliere.romain@neuf.fr
 

New Message Reply Date view Thread view Subject view Author view
 

Back to home