Description Usage Arguments Details Value Author(s) References See Also Examples

View source: R/binda.ranking.R

`binda.ranking`

determines a ranking of predictors by computing corresponding t-scores
between the group means and the pooled mean.

`plot.binda.ranking`

provides a graphical visualization of the top ranking variables

1 2 3 | ```
binda.ranking(Xtrain, L, lambda.freqs, verbose=TRUE)
## S3 method for class 'binda.ranking'
plot(x, top=40, arrow.col="blue", zeroaxis.col="red", ylab="Variables", main, ...)
``` |

`Xtrain` |
A matrix containing the training data set. Note that the rows correspond to observations and the columns to variables. |

`L` |
A factor with the class labels of the training samples. |

`lambda.freqs` |
Shrinkage intensity for the class frequencies. If not specified it is
estimated from the data. |

`verbose` |
Print out some info while computing. |

`x` |
A "binda.ranking" object – this is produced by the binda.ranking() function. |

`top` |
The number of top-ranking variables shown in the plot (default: 40). |

`arrow.col` |
Color of the arrows in the plot (default is |

`zeroaxis.col` |
Color for the center zero axis (default is |

`ylab` |
Label written next to feature list (default is |

`main` |
Main title (if missing, |

`...` |
Other options passed on to generic plot(). |

The overall ranking of a feature is determined by computing a weighted sum of
the squared t-scores. This is approximately equivalent to the mutual information between the response and each variable. The same criterion is used in `dichotomize`

. For precise details see Gibb and Strimmer (2015).

`binda.ranking`

returns a matrix with the following columns:

`idx` |
original feature number |

`score` |
the score determining the overall ranking of a variable |

`t` |
for each group and feature the t-score of the class mean versus the pooled mean |

Sebastian Gibb and Korbinian Strimmer (http://strimmerlab.org).

Gibb, S., and K. Strimmer. 2015. Differential protein expression and peak selection in mass spectrometry data by binary discriminant analysis. Submitted. http://arxiv.org/abs/1502.07959

`binda`

, `predict.binda`

, `dichotomize`

.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | ```
# load "binda" library
library("binda")
# training data set with labels
Xtrain = matrix(c(1, 1, 0, 1, 0, 0,
1, 1, 1, 1, 0, 0,
1, 0, 0, 0, 1, 1,
1, 0, 0, 0, 1, 1), nrow=4, byrow=TRUE)
colnames(Xtrain) = paste0("V", 1:ncol(Xtrain))
is.binaryMatrix(Xtrain) # TRUE
L = factor(c("Treatment", "Treatment", "Control", "Control") )
# ranking variables
br = binda.ranking(Xtrain, L)
br
# idx score t.Control t.Treatment
#V2 2 4.000000 -2.000000 2.000000
#V4 4 4.000000 -2.000000 2.000000
#V5 5 4.000000 2.000000 -2.000000
#V6 6 4.000000 2.000000 -2.000000
#V3 3 1.333333 -1.154701 1.154701
#V1 1 0.000000 0.000000 0.000000
#attr(,"class")
#[1] "binda.ranking"
#attr(,"cl.count")
#[1] 2
# show plot
plot(br)
# result: variable V1 is irrelevant for distinguishing the two groups
``` |

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.