\name{gene.legend} \alias{gene.legend} \title{ Generate a colour bar to use as a legend } \description{ Adds a colour bar to a plot. Used by \code{\link{plotGene}} and \code{\link{gene.strip}} } \usage{ gene.legend(x,y,w,h,col,col.range,border="#dddddd",cex) } \arguments{ \item{x}{x location of legend} \item{y}{y location of legend} \item{w}{width of colour bar. Defaults to 10\% of the plot region } \item{h}{height of colour bar. Defaults to the height of a character} \item{col}{palette used to generate colour bar} \item{col.range}{a \code{range} specifying left and right extents of colour bar} \item{cex}{character expansion} \item{border}{Border colour for each cell in the colour ar} } \details{ Is called by \code{\link{plotGene}} and \code{\link{gene.strip}} by default. Position of the legend can be fine tuned by calling this function directly. } \value{ none } \seealso{\code{\link{plotGene}} \code{\link{gene.strip}}} \references{\url{ http://bioinformatics.picr.man.ac.uk/}} \author{ Crispin Miller } \keyword{ misc } \examples{ if(interactive()) { xmapConnect("human") data(exonmap) plotGene("ENSG00000141510",x.rma,gps=list(1:3,4:6),type="mean-fc",show.legend=FALSE) gene.legend(par()$usr[1]+1000,2,col=col.rd.bl,col.range=c(-5,5),cex=0.75) } }