docs: def cmd():
      """Implementation of plates subcommand.
  
      Other Parameters:
          conf.plates
          conf.scaling
          conf.plot
          conf.core
      """
      sdat = StagyyData(conf.core.path)
      conf.plates.plot = set_of_vars(conf.plates.plot)
      if not conf.plates.vzcheck:
          conf.scaling.dimensional = True
          conf.scaling.factors['Pa'] = 'M'
          main_plates(sdat)
      else:
          seuil_memz = 0
          nb_plates = []
          time = []
          ch2o = []
          istart, iend = None, None
  
          for step in sdat.walk.filter(fields=['T']):
              # could check other fields too
              if conf.plates.timeprofile:
                  time.append(step.timeinfo.loc['t'])
                  ch2o.append(step.timeinfo.loc[0])
              istart = step.isnap if istart is None else istart
              iend = step.isnap
              limits, nphi, dvphi, seuil_memz, vphi_surf =\
                  detect_plates_vzcheck(step, seuil_memz)
              water_profile = np.mean(step.fields['wtr'][0, :, :, 0], axis=0)
              limits.sort()
              sizeplates = [limits[0] + nphi - limits[-1]]
              for lim in range(1, len(limits)):
                  sizeplates.append(limits[lim] - limits[lim - 1])
              lim = len(limits) * [max(dvphi)]
              fig = plt.figure()
              plt.subplot(221)
              plt.axis([0, nphi,
                        np.min(vphi_surf) * 1.2, np.max(vphi_surf) * 1.2])
              plt.plot(vphi_surf)
              plt.subplot(223)
              plt.axis(
                  [0, nphi,
                   np.min(dvphi) * 1.2, np.max(dvphi) * 1.2])
              plt.plot(dvphi)
              plt.scatter(limits, lim, color='red')
              plt.subplot(222)
              plt.hist(sizeplates, 10, (0, nphi / 2))
              plt.subplot(224)
              plt.plot(water_profile)
              misc.saveplot(fig, 'plates', step.isnap)
  
              nb_plates.append(len(limits))
  
          if conf.plates.timeprofile:
              for i in range(2, len(nb_plates) - 3):
                  nb_plates[i] = (nb_plates[i - 2] + nb_plates[i - 1] +
                                  nb_plates[i] + nb_plates[i + 1] +
                                  nb_plates[i + 2]) / 5
              figt = plt.figure()
              plt.subplot(121)
              plt.axis([time[0], time[-1], 0, np.max(nb_plates)])
              plt.plot(time, nb_plates)
              plt.subplot(122)
              plt.plot(time, ch2o)
              misc.saveplot(figt, 'plates_{}_{}'.format(istart, iend))