public static void main(String[] args) throws IOException {

		readData();

		calculateAverageRatings();

		calculateStandardDeviations();

		File base = new File(outputDirectory + fileName);
		if (!base.exists())
			base.createNewFile();
		FileWriter bw = new FileWriter(base.getAbsoluteFile());
		BufferedWriter baseWriter = new BufferedWriter(bw);

		for (Entry<Integer, HashMap<Integer, Integer>> entry : userMovieRatings.entrySet()) {
			int outOfRange = 0;
			int inRange = 0;
			for (Entry<Integer, Integer> ratings : entry.getValue().entrySet()) {
				double avgMinusDev = averageMovieRatings.get(ratings.getKey())
						- standardDeviations.get(ratings.getKey());
				double avgPlusDev = averageMovieRatings.get(ratings.getKey())
						+ standardDeviations.get(ratings.getKey());
//				double avgMinusDev = averageMovieRatings.get(ratings.getKey())
//						- 1.5;
//				double avgPlusDev = averageMovieRatings.get(ratings.getKey())
//						+ 1.5;

				if (ratings.getValue() < avgMinusDev || ratings.getValue() > avgPlusDev) {
					outOfRange++;
				} else {
					inRange++;
				}
			}
			// Print out percentage of how many times the user wasn't in the
			// range of the standard deviation
			baseWriter.write(entry.getKey() + "\t" + ((double) outOfRange / (inRange + outOfRange)) + "\n");

		}
		baseWriter.close();
	}