データ接続と統合Python (Spark)PySparkリファレンスその他

注: 以下の翻訳の正確性は検証されていません。AIPを利用して英語版の原文から機械的に翻訳されたものです。

その他

コレクション

  • array(*cols)
  • array_contains(col, value)
  • size(col)
  • sort_array(col, asc=True)
  • struct(*cols)

並べ替え

  • asc(col)
  • desc(col)

バイナリ

  • bitwiseNOT(col)
  • shiftLeft(col, numBits)
  • shiftRight(col, numBits)
  • shiftRightUnsigned(col, numBits)

null 値の処理

  • coalesce(*cols)
  • isnan(col)
  • isnull(col)

列

  • col(col) or column(col)
  • create_map(*cols)
  • explode(col)
  • expr(str)
  • hash(*cols)
  • input_file_name()
  • posexplode(col)
  • sha1(col)
  • sha2(col, numBits)
  • soundex(col)
  • spark_partition_id()

JSON

  • from_json(col, schema, options={})
  • get_json_object(col, path)
  • json_tuple(col, *fields)
  • to_json(col, options={})

Checkpoint

  • checkpoint(eager=True)
  • localCheckpoint(eager=True)

checkpoint() 関数は DataFrame を一時的にディスクに保存するために使用されます。一方、localCheckpoint() は DataFrame をエグゼキューターのメモリーに保存します。eager パラメーターの値を使用して、DataFrame の Checkpoint を即座に作成するかどうかを設定します(デフォルト値は True)。