Description Usage Arguments Value Author(s) References See Also Examples
This function returns the binary rule for discrimination between data from class k and data from class l
1 | getBinaryRule(object, k, l)
|
object |
An object of class PartitionWithLLR as returned by learnPartitionWithLLR |
k |
an existing label |
l |
an existing label |
A binary classification rule. Can either be an object of class LinearRule or an object of class QuadraticRule
Robin Girard
Fast rate of convergence in high dimensional linear discriminant analysis. R. Girard To appear in Journal of Nonparametric Statistics.\ Very high dimensional discriminant analysis with thresholding estimation. R. Girard. Submitted.
1 2 3 4 5 6 7 8 9 10 11 | #try p=1000 , 5000, ...
p=100; n=20 ; mu=array(0,c(p,4)); mu[1:10,1]=2 ;mu[11:20,2]=2;C=array(c(1,20),p)
mu[21:30,3]=2
x=NULL; y=NULL;
for (k in 1:4){
x=rbind(x,t(array(C^(1/2),c(p,n))*(matrix(rnorm(p*n),nrow=p,ncol=n))+array(mu[,k],c(p,n))));
y=c(y,array(k,n))}
#Learning
LearnedLinearPartitionWithLLR=learnPartitionWithLLR(x,y,procedure='FDRThresh')
Rule=getBinaryRule(LearnedLinearPartitionWithLLR,1,2)
show(Rule)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.