code: public HMM<O> learn(int[][] observations, int iterations) {
          HMM<O> hmm = this;
  
          for (int iter = 0; iter < iterations; iter++) {
              hmm = hmm.iterate(observations);
          }
  
          return hmm;
      }
docs: With this HMM as the initial model, learn an HMM by the Baum-Welch
  algorithm.
  
  @param observations the observation sequences on which the learning is
  based. Each sequence must have a length higher or equal to 2.
  @param iterations the number of iterations to execute.
  @return the updated HMM.