Skip to main content Brad's PyNotes

Posts on Data

  1. Pickle Module

    TL;DR

    The pickle module serializes Python objects to bytes and deserializes them back - enabling object persistence and inter-process communication.

    Interesting!

    Pickle can serialize almost any Python object, including functions, classes, and nested objects - but never unpickle untrusted data as it can execute arbitrary code!

  2. Statistics Module

    TL;DR

    The statistics module provides mathematical statistics functions for calculating averages, spread measures, and correlations without external dependencies.

    Interesting!

    Unlike floating-point calculations, the statistics module can work with Decimal and Fraction types for exact mathematical precision in statistical calculations!