added write confidence files