code: def pivot_ui(
      df,
      outfile_path="pivottablejs.html",
      url="",
      width="100%",
      height="500",
      **kwargs,
  ):
      with io.open(outfile_path, "wt", encoding="utf8") as outfile:
          csv = df.to_csv(encoding="utf8")
          if hasattr(csv, "decode"):
              csv = csv.decode("utf8")
          outfile.write(
              TEMPLATE % dict(csv=csv, kwargs=json.dumps(kwargs))
          )
      return IFrame(src=url or outfile_path, width=width, height=height)
  
label_desc: Use image node_id 1 for calling a global function with example usage: pivot_ui(df, outfile_path, url, width, height) and returns: IFrame