Learn Visidata

Learn Visidata

Data-Science at your fingertips (literally)

  • Cheatsheet

    PM

    Pratyush Mittal

    @pratyushmittal

    VisiData

    Frequency => F
    Sort => [ and ]

    column type: #, @, $ and %

    g is global modifier
    z is to narrow the scope or select variant

    filter:
    |: select rows containing regex
    z|: select rows containing python expr
    ,: select rows with current text

    new columns:
    :: split on regex. Use ( to expand columns
    =: from python expression

    new sheets:
    : from selected rows

    meta:
    shift+S: sheets
    shift+C: columns

    aggregate => z=
    Joining => key (!) , sheets S, select rows s, join &

    Grouping => set aggregator for relevant column +, make group by column as key !, execute groupby F
    Pivot => make group by column as key !, set aggregator for values using + on values you want to see, set pivot headers using Shift + W on another column
    Window function => w (select number rows before and after), use -1 0 to select all previous. then sum(foo_window) to get sum.

    z’: cache column to speed up

    Run any command: <space>

    Other things to look into:

    • histogram
    • unfurl for nested data
    • shift-O: settings

Hosted by

Coders Club of Lucknow