private Map<Integer, Double> calcUptime(File experiment) throws Exception{
        //takes in a file, creates the average of each 1m distance bucket in terms of connected or not
        Map<Integer, List<Integer>> values = new HashMap<Integer, List<Integer>>();
        BufferedReader reader = new BufferedReader(new FileReader(experiment));
        int loc= 0;
        String line;
        boolean service = true;
        int connected = 0;
        while((line = reader.readLine()) != null) { //may need line assignment
            switch(line) {
                case "#Location:":
                    String l = reader.readLine();
                    loc = (int)Math.round(Double.parseDouble(l.substring(l.indexOf("(")+1, l.indexOf(","))));
                    break;
                case "#HasService:":
                    service = Boolean.parseBoolean(reader.readLine());
                    break;
                case "#ShouldBeConnected:":
                    switch (reader.readLine()) {
                        case "true":
                            connected = 1;
                            break;
                        default:
                            connected = 0;
                            break;
                    }
                    if(!service) {
                        if (values.containsKey(loc)) {
                            values.get(loc).add(connected);
                        }
                        else  {
                            List<Integer> nl = new ArrayList<Integer>();
                            nl.add(connected);
                            values.put(loc, nl);
                        }
                    }
                    break;
                default:
                    //do nothing
                    break;
            }
        }
        reader.close();
        Map<Integer, Double> average = new HashMap<Integer, Double>();
        for (int location: values.keySet()) {
            double sum = 0;
            for (int conn: values.get(location)) {
                sum = sum + conn;
            }
            double av = (sum/values.get(location).size());
            average.put(location, av);
        }
        return average;
    }