public void mutate(Sequence reference){
        for(int i = 0; i < reference.length(); i++){
            //insert new bases
            while(insert()){
                mutated.append(new Base());
            }
            //if delete skip reference base
            if(delete()){
            }
            else{
                if(snp()){         //if not delete check if snp
                    while(true){
                        Base newBase = new Base();  //get a different base and append it
                        if(!newBase.equals(reference.baseAt(i))){
                            mutated.append(newBase);
                            break;
                        }
                    }
                }
                else{      //if not snp, insert that reference base
                    mutated.append(reference.baseAt(i));
                }
            }
        }
    }