code: public JSONObject getJsonFormatted(Map<String, String> dataMap) {
          JSONObject oneRowJson = new JSONObject();
  
          for (int i = 0; i < outTemplate.length; i++) {
              oneRowJson.put(outTemplate[i], dataMap.get(outTemplate[i]));
          }
  
  
          return oneRowJson;
      }
docs: Given an array of variable names, returns a JsonObject
  of values.
  
  @param dataMap an map containing variable names and their corresponding values
  names.
  @return a json object of values