public Data[] reader(int num, int tol, File d){ //Take a frequency, tolerance, and directory
        String directory = d.getName(); //Get the name of the directory
        File dir = new File(directory); //Create a file out of the directory
        String[] temp = dir.list(); //List all of the files
        files = new HashTable(dir.list().length*(dir.list().length - 1)); //Create a hashTable that will be N(N-1) files large
        fileString = new ArrayList<String>();
        percents = new ArrayList<Integer>();
        n = num; 
        for(int i = 0; i < temp.length; i++)
        {
            String[] prev = null; //Create an array to show the first compared file
            if(temp[i].endsWith(".txt")){
                File start = new File(dir + "\\" + temp[i]); //Get the file of the first file to compare
                File startCopy = new File(temp[i]); //Get the name without the directory
                prev = file.read(start).split("\\s+"); //Set prev to an array that is the string split up by spaces

                for(int b = i +1; b < temp.length;b++){ //Loop through the array from this spot and onward
                    if(temp[b].endsWith(".txt")){
                        File curr = new File(dir + "\\" + temp[b]); //Create a second file to be compared too
                        String s = file.read(curr); //Have the second file's name without the directory
                        int tempNum = compare(prev,s); //Get the number of hits between the files

                        if(tempNum >= tol){ //Check to see if the number of hits is greater than or equal to the tolerance
                            percents.add(getNumWords(prev)); //Add the amount of words to percents (Note data is manipulated later)
                            fileString.add("[" + startCopy + "]" + ", " + "[" + temp[b] + "]" + ": "); //A String of the files compared is stored
                            files.put("[" + startCopy + "]" + ", " + "[" + temp[b] + "]" + ": ",tempNum); //The information is stored in the hashTable with the String being the key
                                                                                                          //If the hits are used as the key, collisions occur
                        }
                    }
                }
            }
        }
        Data[] data = new Data[fileString.size()]; //Create an array of Data objects
        for(int b = 0; b < fileString.size(); b++){ //Loop through the files
            String s = fileString.get(b); //Get the current string
            double p = ((int)files.get(s) * 1.00 / percents.get(b)) * 100; //Take the amount of hits divided by the total number of words multiplied by 100 to get the percent copied
            data[b] = new Data(s,(int)files.get(s),p); //Add the new data into the array
        }
        Arrays.sort(data,new revComparator()); //Sort the array data with a custom comparator
        return data; //Return the sorted data
    }