# mailAnalyzer.js
A library to get information about a dataset of mails
that will be used by UIConsult to improve their analyzing of the work of employees.
----------
## How to use
In order to use the library, you need to open a command-line interface in the source of this library (in frenglish-gl02-git) and launch
node mailAnalyzer.js
This will open the help for the library, other commands will be browsed below.
All commands use the dataset of mails in `mail` containing mails of UIConsult collaborators.
------
## Commands
### Set Up
node mailAnalyzer.js mailPath <path>
This command changes the actual path to the new path if it exists (Note: you can also manually edit the path.txt file)
### Graph
node mailAnalyzer.js graph <mail>
This command allow you to visualize in a graph how many mails were exchanged with others for a given address mail. It creates a scatter plot in SVG format.
* `mail` Mail address of the collaborator
### Search
node mailAnalyzer.js search <condition> <value>
This command is a search tool for person. It displays a list of mail matching the name, mail or surname given in arguments. Let's detail arguments :
* `condition` What condition you want your search to match between :
* name : Searching in names of sender or receiver
* surname : Searching in surnames of sender or receiver
* mail : Searching in mail addresses of sender or receiver
* `value` The name, surname or mail address you are searching
### Buzzy days
node mailAnalyzer.js buzzy <targetPerson>
This command displays all mails of a target person that were sent during weekend or between 10:00pm and 8:00am of the
next day.
### period search
node mailAnalyzer period <time1-time2>
This command displays all mails that were sent during a certain period.
* `time1-time2` just like 01-20, 12-19
### Top 10 Interlocutors
node mailAnalyzer.js topinterlocutor <mail>
This command displays the 10 interlocutors a given collaborator has exchanged with the most.
* `mail` Mail address of the collaborator
### All Interlocutors
node mailAnalyzer.js allinterlocutor <mail>
This command displays all interlocutors for a given collaborator has exchanged with.
* `mail` Mail address of the collaborator
### Top 10 terms
node mailAnalyzer.js topterm <mail>
This command displays the 10 terms the most used by a given collaborator.
* `mail` Mail address of the collaborator
### find contact
node mailAnalyzer findcontact <name>
This command displays find the contact address of someone.
* `name` First and LastName of the collaborator,like findcontact "John Arnold"