next up previous index
Next: Trees argument Up: POY 4.0 Tutorials: general Previous: Searching the local neighborhood   Index

Searching the local neighborhood (again)

  1. Although wipe () seems like a handy command, in interactive tests it would be desirable to have other means to store the state of the program and continue from there later on. The store () and use () commands serve this purpose.

  2. store ("name") will store the current state of the program (that is all the data, trees, and support values) under the name label. Conversely, the command use ("name") sets the current state of the program to that which was stored under the label name. For example:
                (* These are comments in a POY script *)
                wipe ()
                read ("course.fasta", "built_trees.tree")
                report (data, treestats)
                (* At this point you can see that we
                have loaded some molecular data as well as 
                initial trees. We will store it under the 
                label initial_data. *)
                store ("initial_data")
                select ()
                (* We will now modify the data, using a 
                command that will be introduced later. *)
                transform (static_approximation)
                report (data, treestats)
                (* Notice that now we are only analyzing 
                static homology characters. *)
                store ("static_data")
                use ("initial_data")
                report (data, treestats)
                (* See the characters are the same as the 
                originals? *)
                use ("static_data")
                report (data, treestats)
                (* Is it what you expected? *)

  3. We can now do things more efficiently. Lets compare SPR and TBR again:
                wipe ()
                read ("course.fasta", "built_trees.tree")
                store ("initial")
                swap (tbr)
                report (treestats)
                use ("initial")
                swap (spr)
                report (treestats)

  4. Finally make sure that the best trees that we found are saved for future use (we will need them later).
                report ("swap_course.tree")
                exit ()

Andres Varon,