public double[] mittelWert()
    {
        boolean fertig = true;
        int i = 0;
        double[] werte = new double[2];
        double temp = 0;
        ArrayList<Double> list = new ArrayList<>();
        try
        {
            ResultSet set = read("SELECT WERT1, WERT2 FROM OPERATION ORDER BY ZEIT DESC");
            while(set.next() && fertig)
            {
                list.add(set.getDouble("WERT1"));
                list.add(set.getDouble("WERT2"));
                i += 1;
                if(i == 5)
                {
                    fertig = false;
                }
            }
            set.close();
        } 
        catch(SQLException e)
        {
            System.out.println("SQL Fehler");
        }
        for(int n = 0; n<10; n++)
        {
            temp += list.get(n);
        }
        temp = temp/10;
        werte[0] = temp;
        temp = 0;
        for(int x = 0; x < 10; x++)
        {
            temp += Math.pow((list.get(x)-werte[0]), 2);
        }
        temp = Math.sqrt((temp/10));
        werte[1] = temp;
        return werte;
    }