Changeset 161


Ignore:
Timestamp:
Sep 21, 2004, 12:24:45 PM (17 years ago)
Author:
Peter
Message:

.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/test/test_consensus_inputranker.cc

    r158 r161  
    3131  theplu::cpptools::ConsensusInputRanker cir(data,target,roc,10,3);
    3232
    33   for (size_t i=0; i<3; i++){
    34     cout << cir.id(i) << "\n";
    35     cout << cir.rank(i) << "\n";
    36   }
    37  
    3833  if (cir.id(0)!=2 || cir.id(1)!=0 || cir.id(2)!=1){
    3934    cerr << "wrong id" << endl;
     
    4641  }
    4742
     43  theplu::gslapi::matrix flag(data.rows(),data.columns(),1);
     44  theplu::cpptools::ConsensusInputRanker cir2(data,target,flag,roc,10,3);
     45
     46  if (cir2.id(0)!=2 || cir2.id(1)!=0 || cir2.id(2)!=1){
     47    cerr << "wrong id" << endl;
     48    return -1;
     49  }
     50 
     51  if (cir2.rank(0)!=1 || cir2.rank(1)!=2 || cir2.rank(2)!=0){
     52    cerr << "wrong rank" << endl;
     53    return -1;
     54  }
     55
    4856 
    4957  return 0;
Note: See TracChangeset for help on using the changeset viewer.