Last data update: 2014.03.03

R: Plot 1D graph of results from between group analysis
between.graphR Documentation

Plot 1D graph of results from between group analysis

Description

Plots a 1D graph, of results of between group analysis similar to that in Culhane et al., 2002.

Usage

between.graph(x, ax = 1, cols = NULL, hor = TRUE, scaled=TRUE, centnames=NULL, varnames=NULL, ...)

Arguments

x

Object of the class bga resulting from a bga analysis.

ax

Numeric. The column number of principal component ($ls and $li) to be used. Default is 1. This is the first component of the analysis.

cols

Vector of colours. By default colours are obtained using getcol

hor

Logical, indicating whether the graph should be plotted horizontally or vertically. The default is a horizontal plot.

scaled

Logical, indicating whether the coordinates in the graph should be scaled to fit optimally in plot. Default is TRUE

centnames

A vector of variables labels. Default is NULL, if NULL the row names of the centroid $li coordinates will be used.

varnames

A vector of variables labels. Default is NULL, if NULL the row names of the variable $ls coordinates will be used.

...

further arguments passed to or from other methods

Details

This will produce a figure similar to Figure 1 in the paper by Culhane et al., 2002.

between.graph requires both samples and centroid co-ordinates ($ls, $li) which are passed to it via an object of class bga. If cases are to be coloured by class, it also requires a $fac factor which is also passed to it via an object of class bga.

To plot a 1D graph from other multivariate analysis such as PCA (dudi.pca), COA (dudi.coa), or coinertia analysis. Please use graph1D.

Author(s)

Aedin Culhane

References

Culhane AC, et al., 2002 Between-group analysis of microarray data. Bioinformatics. 18(12):1600-8.

See Also

graph1D

Examples

data(khan)
if (require(ade4, quiet = TRUE)) {
khan.bga<-bga(khan$train, khan$train.classes)
}

between.graph(khan.bga)
between.graph(khan.bga, ax=2, lwd=3, cex=0.5, col=c("green","blue", "red", "yellow"))
between.graph(khan.bga, ax=2,  hor=FALSE, col=c("green","blue", "red", "yellow"))

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(made4)
Loading required package: ade4
Loading required package: RColorBrewer
Loading required package: gplots

Attaching package: 'gplots'

The following object is masked from 'package:stats':

    lowess

Loading required package: scatterplot3d
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/made4/between.graph.Rd_%03d_medium.png", width=480, height=480)
> ### Name: between.graph
> ### Title: Plot 1D graph of results from between group analysis
> ### Aliases: between.graph
> ### Keywords: multivariate hplot
> 
> ### ** Examples
> 
> data(khan)
> if (require(ade4, quiet = TRUE)) {
+ khan.bga<-bga(khan$train, khan$train.classes)
+ }
> 
> between.graph(khan.bga)
> between.graph(khan.bga, ax=2, lwd=3, cex=0.5, col=c("green","blue", "red", "yellow"))
> between.graph(khan.bga, ax=2,  hor=FALSE, col=c("green","blue", "red", "yellow"))
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>