[adegenet-forum] s.class: how to avoid box around plotting area

Thibaut Jombart thibautjombart at gmail.com
Tue Oct 31 13:04:41 CET 2017


Hello,

it is documented in ?s.class - see cellipse argument.

Best
Thibaut

--
Dr Thibaut Jombart
Lecturer, Department of Infectious Disease Epidemiology, Imperial College London
Head of RECON: repidemicsconsortium.org
WHO Consultant - outbreak analysis
sites.google.com/site/thibautjombart/
Twitter: @TeebzR
+44(0)20 7594 3658


On 27 October 2017 at 10:10, Walter Durka <walter.durka at ufz.de> wrote:
> Hi,
>
> I use the standard plot command to display results of PCoA and s.class to
> add the stars and elypses; and I combine two plots for axes 1+2 and 1+3.
> However, s.class adds a box around the full plotting area, which  looks
> nasty, in particular as I combined two plots (see file attached).
>
> How can I avoid that s.class adds these boxes?
>
> regards
>
> Walter
>
> #######################################
>
> pco1<-dudi.pco(d.dist,scannf=F,nf=6)
>
>  par(mfrow=c(2,1), mar=c(2,4,2,2)+0.1,mgp=c(3,1,0))
>  par( mar=c(.5,4,2,2)+0.1)
>
>   ## basic plot
>  plot(pco1$tab[,1:2], col=myCol, cex=2, pch=myPch, xaxt='n',yaxt='n',
>       xlab=paste("PCoA1
> (",format(PCO1_exV,digits=2),"%)",sep=""),ylab=paste("PCoA2
> (",format(PCO2_exV,digits=2),"%)",sep=""),
>       mgp=c(1,.5,0))
>  mtext("A",3,at=min(pco1$tab[,1]) -
> (max(pco1$tab[,1])-min(pco1$tab[,1]))/9,cex=1.5,font=2)
>  # groups
>  s.class(pco1$tab[,1:3],xax=1,yax=2,fac =d.pop$pop,addaxes=T,col=popc,
>          cpoint=0.5, grid=F, cstar=1,axesell=F,
> sub="",possub="topleft",add.plot=T)
>
>  par( mar=c(2,4,.5,2)+0.1)
>  plot(pco1$tab[,3]~pco1$tab[,1], col=myCol, cex=2, pch=myPch,
> xaxt='n',yaxt='n',
>       xlab=paste("PCoA1
> (",format(PCO1_exV,digits=2),"%)",sep=""),ylab=paste("PCoA2
> (",format(PCO2_exV,digits=2),"%)",sep=""),
>       mgp=c(1,.5,0))
>  mtext("B",3,at=min(pco1$tab[,1]) -
> (max(pco1$tab[,1])-min(pco1$tab[,1]))/9,cex=1.5,font=2)
>  #  groups
>  s.class(pco1$tab[,1:3],xax=1,yax=3,fac
> =d.pop$pop,addaxes=T,col=popc,#funky(9),
>          cpoint=0.5, grid=F, cstar=1,axesell=F,
> sub="",possub="topleft",add.plot=T)
>   ####################################################
>
>
>
> --
>
> *****
> Dr. Walter Durka
> Department Biozönoseforschung
> Department of community ecology
>
> Helmholtz-Zentrum für Umweltforschung GmbH - UFZ
> Helmholtz Centre for Environmental Research - UFZ
> Theodor-Lieser-Str. 4 / 06120 Halle / Germany
>
> walter.durka at ufz.de / http://www.ufz.de/index.php?en=798
> phone +49 345 558 5314 / Fax +49 345 558 5329
>
> --------------------------------------------------------------------------------------------
>
> Sitz der Gesellschaft: Leipzig
> Registergericht: Amtsgericht Leipzig
> Handelsregister Nr. B 4703
> Vorsitzender des Aufsichtsrats: MinDirig Wilfried Kraus
> Wissenschaftlicher Geschäftsführer: Prof. Dr. Georg Teutsch
> (Scientific Managing Director)
> Administrative Geschäftsführerin: Dr. Heike Graßmann
> (Administratve Managing Director)
>
> --------------------------------------------------------------------------------------------
>
>
> _______________________________________________
> adegenet-forum mailing list
> adegenet-forum at lists.r-forge.r-project.org
> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/adegenet-forum


More information about the adegenet-forum mailing list