Re: [R-sig-phylo] Plotting sampled-ancestor trees in R

2015-12-09 Thread Roger Close
Hi Dave, Emmanuel and Joseph,

Thanks very much for your suggestions. The output of BEAST, at least, is an
ordinary Newick/NEXUS file with ancestors represented as tips on the ends
of zero-length branches (see attached).

One way to proceed would be to drop the tips that correspond to ancestors
and then add them back on using edge labels. However, I see that paleotree
designates ancestors using $anag.tips; is there a tool for plotting this
type of tree?

Cheers,
Roger



---
Roger Close, Postdoctoral Research Associate
Department of Earth Sciences, Oxford University
South Parks Road
Oxford OX1 3AN
United Kingdom

On 8 December 2015 at 18:56, David Bapst  wrote:

> Hi Roger,
>
> I'm not aware of any existing solution. Could you send around a small
> example of the data format of an output sampled ancestor tree from
> BEAST or MrBayes? Are they just typical Newick/NEXUS format with
> ancestors indicated tipis with zero-length branches or something more
> complicated?
>
> Remarkably I've not looked at the formatting of one, but obviously
> plotting SA trees is something the community will need in the near
> future.
>
> Cheers,
> -Dave
>
> On Tue, Dec 8, 2015 at 5:46 AM, Roger Close  wrote:
> > Hi all,
> >
> > Does anyone know of a way to plot sampled-ancestor trees in R such that
> > ancestors lie on branches, rather than being zero-length terminals that
> > follow a bifurcation?
> >
> > Many thanks,
> > Roger
> >
> > ---
> > Roger Close, Postdoctoral Research Associate
> > Department of Earth Sciences, Oxford University
> > South Parks Road
> > Oxford OX1 3AN
> > United Kingdom
> >
> > [[alternative HTML version deleted]]
> >
> > ___
> > R-sig-phylo mailing list - R-sig-phylo@r-project.org
> > https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
> > Searchable archive at
> http://www.mail-archive.com/r-sig-phylo@r-project.org/
>
>
>
> --
> David W. Bapst, PhD
> Adjunct Asst. Professor, Geology and Geol. Eng.
> South Dakota School of Mines and Technology
> 501 E. St. Joseph
> Rapid City, SD 57701
>
> http://webpages.sdsmt.edu/~dbapst/
> http://cran.r-project.org/web/packages/paleotree/index.html
>


sa.tree.tre
Description: Binary data
___
R-sig-phylo mailing list - R-sig-phylo@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
Searchable archive at http://www.mail-archive.com/r-sig-phylo@r-project.org/

Re: [R-sig-phylo] Plotting sampled-ancestor trees in R

2015-12-08 Thread Emmanuel Paradis

Hi Jo & Roger,

edgelabels() has the option 'date' which helps to annotate the branches 
of a tree:


set.seed(1)
tx <- rcoal(3)
plot(tx)
axisPhylo()
edgelabels(edge = 1, date = 1, pch = 19, col = "red")

Best,

Emmanuel

Le 08/12/2015 16:32, Joseph Brown a écrit :

Roger,

Are you looking for something like this?









It is just a matter of finding the coordinates on the last plot:

lastPP<- get("last_plot.phylo", envir=.PlotPhyloEnv);

and laying down points where you want them.

If this is along the lines of what you want, I can make the code a bit
more general and send it along.

JWB.

Joseph W. Brown
Post-doctoral Researcher, Smith Laboratory
University of Michigan
Department of Ecology & Evolutionary Biology
Room 2071, Kraus Natural Sciences Building
Ann Arbor MI 48109-1079
josep...@umich.edu 




On 8 Dec, 2015, at 07:46, Roger Close > wrote:

Hi all,

Does anyone know of a way to plot sampled-ancestor trees in R such that
ancestors lie on branches, rather than being zero-length terminals that
follow a bifurcation?

Many thanks,
Roger

---
Roger Close, Postdoctoral Research Associate
Department of Earth Sciences, Oxford University
South Parks Road
Oxford OX1 3AN
United Kingdom

[[alternative HTML version deleted]]

___
R-sig-phylo mailing list - R-sig-phylo@r-project.org

https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
Searchable archive at
http://www.mail-archive.com/r-sig-phylo@r-project.org/




___
R-sig-phylo mailing list - R-sig-phylo@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
Searchable archive at http://www.mail-archive.com/r-sig-phylo@r-project.org/



___
R-sig-phylo mailing list - R-sig-phylo@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
Searchable archive at http://www.mail-archive.com/r-sig-phylo@r-project.org/

Re: [R-sig-phylo] Plotting sampled-ancestor trees in R

2015-12-08 Thread David Bapst
Hi Roger,

I'm not aware of any existing solution. Could you send around a small
example of the data format of an output sampled ancestor tree from
BEAST or MrBayes? Are they just typical Newick/NEXUS format with
ancestors indicated tipis with zero-length branches or something more
complicated?

Remarkably I've not looked at the formatting of one, but obviously
plotting SA trees is something the community will need in the near
future.

Cheers,
-Dave

On Tue, Dec 8, 2015 at 5:46 AM, Roger Close  wrote:
> Hi all,
>
> Does anyone know of a way to plot sampled-ancestor trees in R such that
> ancestors lie on branches, rather than being zero-length terminals that
> follow a bifurcation?
>
> Many thanks,
> Roger
>
> ---
> Roger Close, Postdoctoral Research Associate
> Department of Earth Sciences, Oxford University
> South Parks Road
> Oxford OX1 3AN
> United Kingdom
>
> [[alternative HTML version deleted]]
>
> ___
> R-sig-phylo mailing list - R-sig-phylo@r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
> Searchable archive at http://www.mail-archive.com/r-sig-phylo@r-project.org/



-- 
David W. Bapst, PhD
Adjunct Asst. Professor, Geology and Geol. Eng.
South Dakota School of Mines and Technology
501 E. St. Joseph
Rapid City, SD 57701

http://webpages.sdsmt.edu/~dbapst/
http://cran.r-project.org/web/packages/paleotree/index.html

___
R-sig-phylo mailing list - R-sig-phylo@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
Searchable archive at http://www.mail-archive.com/r-sig-phylo@r-project.org/