-class Alceste(AnalyseText) :
- def doanalyse(self) :
- self.parametres['type'] = 'alceste'
- self.pathout.basefiles(ChdTxtPathOut)
- self.actives, lim = self.corpus.make_actives_nb(self.parametres['max_actives'], 1)
- self.parametres['eff_min_forme'] = lim
- self.parametres['nbactives'] = len(self.actives)
- if self.parametres['classif_mode'] == 0 :
- lenuc1, lenuc2 = self.corpus.make_and_write_sparse_matrix_from_uc(self.actives, self.parametres['tailleuc1'], self.parametres['tailleuc2'], self.pathout['TableUc1'], self.pathout['TableUc2'], self.pathout['listeuce1'], self.pathout['listeuce2'])
- self.parametres['lenuc1'] = lenuc1
- self.parametres['lenuc2'] = lenuc2
- elif self.parametres['classif_mode'] == 1 :
- self.corpus.make_and_write_sparse_matrix_from_uces(self.actives, self.pathout['TableUc1'], self.pathout['listeuce1'])
- elif self.parametres['classif_mode'] == 2 :
- self.corpus.make_and_write_sparse_matrix_from_uci(self.actives, self.pathout['TableUc1'], self.pathout['listeuce1'])
- Rscript = self.printRscript()
- self.doR(Rscript, dlg = self.dlg, message = 'CHD...')
-
- self.corpus.make_ucecl_from_R(self.pathout['uce'])
- self.corpus.make_and_write_profile(self.actives, self.corpus.lc, self.pathout['Contout'])
- self.sup, lim = self.corpus.make_actives_nb(self.parametres['max_actives'], 2)
- self.corpus.make_and_write_profile(self.sup, self.corpus.lc, self.pathout['ContSupOut'])
- self.corpus.make_and_write_profile_et(self.corpus.lc, self.pathout['ContEtOut'])
- self.clnb = len(self.corpus.lc)
- self.parametres['clnb'] = self.clnb
- Rscript = self.printRscript2()
- self.doR(Rscript, dlg = self.dlg, message = 'profils et A.F.C. ...')
- self.time = time() - self.t1
- minutes, seconds = divmod(self.time, 60)
- hours, minutes = divmod(minutes, 60)
- self.parametres['time'] = '%.0fh %.0fm %.0fs' % (hours, minutes, seconds)
- self.print_graph_files()