Welcome, Guest. Please Login
YaBB - Yet another Bulletin Board
 
  HomeHelpSearchLogin  
 
Pages: 1 2 
Individual substitutions on branches? (Read 8298 times)
Sarah
YaBB Newbies
*
Offline



Posts: 47
Still trying
Reply #15 - Nov 15th, 2006 at 10:59am
 
I'm returning to this task after a two-month hiatus. HyPhy is no longer crashing, but I also can't get CodonMutationToTreeMapper.bf to work using the GUI on my Mac.

Here's what I do:

1. I open a data set, create a partition, select a tree and a model, and set parameters to local. I then build a likelihood function. I save the likelihood function using the gears button, as Sergei suggested. A window pops up asking me if I want to include an optimization step; I say yes. (Should I optimize now instead?)

2. I then open the file to which I saved the likelihood function and change the function's name as Art described to "lf". (I haven't included the code Sergei wrote.)

3. I then select File > Open Batch File and choose CodonMutationToTreeMapper.bf. The GUI terminal window says it's reconstructing ancestors, prints 10410.4 two times on the screen, and a "Dead End" window appears, saying,

"An error occured:
DataSet/DataSetFilter filteredData has not been initialized
Current BL Command:Harvest Frequencies into matrix observed CEFV from DataSet  filteredData with unit size = 3 with atom size = 3 wth position specific flag = 0
Partition:
Curren operation/job has been terminated."

Another "Dead End" window appears, complaining about setupMapToTree(0).

Is there a reference for this bf short of the code itself? Should I scrap the GUI and try command line on Linux?

Thanks so much for your help and patience.

Sarah
Back to top
 
 
IP Logged
 
Sergei
YaBB Administrator
*****
Offline


Datamonkeys are forever...

Posts: 1658
UCSD
Gender: male
Re: Still trying
Reply #16 - Nov 15th, 2006 at 11:29am
 
Dear Sarah,

CodonMutationToTreeMapper.bf is really quite unfriendly - I wrote it to make figures for one of our papers. It expects things (likelihood functions, trees, filters) to be named a certain way, or it fails.

A simple way to get it to work though (use the GUI), is to run a standard analysis (e.g. AnalyzeCodonData.bf) - as it will produce appropriately named objects. When your analysis is done, you can save the LF if you want (for later), and use the gears button to call CodonMutationToTreeMapper.bf. It will write a PostScript file mapping all inferred substitutions for a given site. You can view PS files in Preview on a Mac, or ghostscript (ghostview) on Linux/Windows.

Cheers,
Sergei

P.S. I'll make the mapping utility more user friendly, if I ever find the time.
Back to top
 

Associate Professor
Division of Infectious Diseases
Division of Biomedical Informatics
School of Medicine
University of California San Diego
WWW WWW  
IP Logged
 
Sarah
YaBB Newbies
*
Offline



Posts: 47
Re: Individual substitutions on branches?
Reply #17 - Nov 16th, 2006 at 10:57am
 
Great! It works! I ran AnalyzeCodonData.bf as you suggested and then chose CodonMutationToTreeMapper.bf from the gears button.

I'm thinking I might try to modify the bf so that the tree shows tip labels. I have a hard time reading on which branches the substitutions occur (the branches are also very dense relative to the size of the letters). Is there a way to print substitutions from a range of codons on the tree, rather than the substitutions associated with one residue at a time?

I think it'd be good practice to try to modify the code myself. My goal is to show the (dis)appearance of glycosylation sites on the tree.

Thanks again,
Sarah
Back to top
 
 
IP Logged
 
Sergei
YaBB Administrator
*****
Offline


Datamonkeys are forever...

Posts: 1658
UCSD
Gender: male
Re: Individual substitutions on branches?
Reply #18 - Nov 16th, 2006 at 11:09am
 
Dear Sarah,

The font scaling thing should be resolved by removing lines 452 and 453 in the file (which fix the font size at 11), and let the drawing routines decide what size is appropriate.

If you want to label the leaves, you can edit line 307 to read

Code:
nodeSpec ["TREE_OUTPUT_BRANCH_LABEL"] = "__FONT_SIZE__ 2 idiv\n__FONT_SIZE__ 3 idiv\nneg\nrmoveto\n("+cd3+") show";
 



PostScript based tree drawing is pretty ugly to get your head around, I am afraid...

Cheers,
Sergei
Back to top
 

Associate Professor
Division of Infectious Diseases
Division of Biomedical Informatics
School of Medicine
University of California San Diego
WWW WWW  
IP Logged
 
Pages: 1 2