caca
This commit is contained in:
parent
7e7fae17ef
commit
501f644eda
|
|
@ -8,19 +8,20 @@ public class Main {
|
|||
|
||||
ListeAvis listeAvis = new ListeAvis(cheminFichierExcel);
|
||||
|
||||
listeAvis.afficherAvis();
|
||||
// Dictionnaire dictionnaire = new Dictionnaire("C:\\Users\\Qpelu\\Downloads\\dictionnaire.csv");
|
||||
// listeAvis.afficherAvis();
|
||||
Dictionnaire dictionnaire = new Dictionnaire();
|
||||
|
||||
// Avis a = new Avis(0, "szzn", "salut j'ai adoré ce film magnifique", 0);
|
||||
|
||||
|
||||
/* Avis.Analyse(a, dictionnaire);
|
||||
// Avis.Analyse(a, dictionnaire);
|
||||
|
||||
|
||||
dictionnaire.apprentissageSentiment(listeAvis.getListeAvis());
|
||||
|
||||
dictionnaire.sauvegarderDictionnaireCSV(cheminSauvegarde);*/
|
||||
|
||||
dictionnaire.sauvegarderDictionnaireCSV(cheminSauvegarde);
|
||||
dictionnaire.getDico()
|
||||
;
|
||||
///Dictionnaire d =new Dictionnaire("C:\\Users\\Qpelu\\Downloads\\dictionnaire.csv");
|
||||
//System.out.println(d);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@ package Main;
|
|||
|
||||
public class Mot {
|
||||
private String nom;
|
||||
private int sentiment;
|
||||
private double sentiment;
|
||||
private int apparitionsTotal;
|
||||
private int apparitionsPositives;
|
||||
|
||||
|
|
@ -12,7 +12,7 @@ public class Mot {
|
|||
this.apparitionsTotal = 0;
|
||||
this.apparitionsPositives = 0;
|
||||
}
|
||||
public Mot(String nom, int sentiment, int apparitionsTotal,int apparitionsPositives) {
|
||||
public Mot(String nom, double sentiment, int apparitionsTotal,int apparitionsPositives) {
|
||||
this.nom = nom;
|
||||
this.sentiment = sentiment;
|
||||
this.apparitionsTotal = apparitionsTotal;
|
||||
|
|
@ -23,12 +23,12 @@ public class Mot {
|
|||
return nom;
|
||||
}
|
||||
|
||||
public int getSentiment() {
|
||||
public double getSentiment() {
|
||||
return sentiment;
|
||||
}
|
||||
|
||||
public void setSentiment(double sentiment) {
|
||||
this.sentiment = (int) (sentiment * 100);
|
||||
this.sentiment = (double) (sentiment * 100);
|
||||
}
|
||||
|
||||
public void incrementerApparitionsTotal() {
|
||||
|
|
|
|||
Loading…
Reference in New Issue