liwca.read_dic

On this page

liwca.read_dic#

liwca.read_dic(fp, **kwargs)[source]#

Read a binary LIWC dictionary from a .dic file.

The .dic format is binary-only by spec: there is no weighted variant. For weighted dictionaries see read_dicx_weighted.

Parameters:
  • fp (str or Path) – Path to a .dic file.

  • **kwargs (Any) – Forwarded to open (e.g. encoding="latin-1" for legacy files).

Returns:

Validated binary dictionary DataFrame (int8 cells, 0/1).

Return type:

pandas.DataFrame