]> git.donarmstrong.com Git - plotprotein.git/blobdiff - R/plot.clustal.R
change position of names and justification
[plotprotein.git] / R / plot.clustal.R
index 83c9b94bb5982c5cc6407aee0fbee09e25d01e06..ae9935214d0cbe815595cde0ba2b0d261aa6da1c 100644 (file)
@@ -169,15 +169,16 @@ plot.clustal <- function(clustal,tree=NULL,refseq=1,refseq.start=1) {
     ## plot the position strings
     position.strings <- seq(refseq.start,by=1,length.out=ncol(clustal))
     if(length(position.strings) < 10) {
-        wanted.position.strings <- postiion.strings %% 2 == 0
+        wanted.position.strings <- position.strings %% 2 == 0
     } else {
         wanted.position.strings <- position.strings %% 5 == 0
     }
     position.strings <- as.character(position.strings)
     position.strings[!wanted.position.strings] <- ""
     grid.text(position.strings,
-              y=unit((length(clustal.names)-1)/2+1,"lines")+unit(0.5,"npc"),
+              y=unit((length(clustal.names)-1)/2+0.6,"lines")+unit(0.5,"npc"),
               x=unit(symbol.pos.x,"mm")+symbol.offset.x,
-              rot=90
+              rot=90,
+              just=c("left","center")
               )
 }