code: function toValue(type, value) {
      switch (type) {
          case "datetime":
              return value instanceof Date ? value : new Date(parseInt(value));
          case "integer":
              return parseInt(value, 10);
          case "float":
              return parseFloat(value);
      }
      return value;
  }
docs: ****************************************************************************
  
  Copyright (c) 2017, the Perspective Authors.
  
  This file is part of the Perspective library, distributed under the terms of
  the Apache License 2.0.  The full license can be found in the LICENSE file.