Skip to main content

An implementation of the DataFrame specification in Python

Project description

Pydf: An Implementation of the DataFrame specification in Python

This is the official implementation of the DataFrame specification provided by Raven Computing.

Getting Started

This library is available on PyPI.

Install via:

pip install raven-pydf

For more information see pypi.org.

After installation you can use the entire DataFrame API by importing one class:

from raven.struct.dataframe import DataFrame

# read a DataFrame file into memory
df = DataFrame.read("/path/to/myFile.df")

# show the first 10 rows on stdout
print(df.head(10))

Alternatively, you can import all concrete Column types directly, for example:

from raven.struct.dataframe import (DefaultDataFrame,
                                    IntColumn,
                                    FloatColumn,
                                    StringColumn)

# create a DataFrame with 3 columns and 3 rows
df = DefaultDataFrame(
        IntColumn("A", [1, 2, 3]),
        FloatColumn("B", [4.4, 5.5, 6.6])
        StringColumn("C", ["cat", "dog", "horse"]))

print(df)

Compatibility

This library requires Python3.7 or higher.

Internally, this library uses Numpy for array operations. The minimum required version is v1.19.0

Documentation

The unified documentation is available here.

Development

If you want to change code of this library or if you want to include it manually as a dependency without installing via PIP, you can do so by cloning this repository.

Setup

We are using virtual environments and the virtualenvwrapper utilities for all of our Python projects. If you are running on Linux then you can set up your development environment by sourcing the setup.sh script. This will create a virtual environment pydf for you and install all dependencies:

source setup.sh

Running Tests

Execute all unit tests via:

python -m unittest

Linting

Run pylint to perform static code analysis of the source code via:

pylint raven

License

This library is licensed under the Apache License Version 2 - see the LICENSE for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

raven-pydf-1.0.2.tar.gz (62.1 kB view details)

Uploaded Source

Built Distribution

raven_pydf-1.0.2-py3-none-any.whl (88.5 kB view details)

Uploaded Python 3

File details

Details for the file raven-pydf-1.0.2.tar.gz.

File metadata

  • Download URL: raven-pydf-1.0.2.tar.gz
  • Upload date:
  • Size: 62.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.5

File hashes

Hashes for raven-pydf-1.0.2.tar.gz
Algorithm Hash digest
SHA256 7321f0ed75694de74f13fcb68f33d81c1327ef8808e20ff468b69611f436c78f
MD5 2dabf90c92734fd7bd63d660298922c4
BLAKE2b-256 020cb2b3d43fbf0ba640d298bbace2c4a0c7c320de502935ba52d2ab5b298f30

See more details on using hashes here.

File details

Details for the file raven_pydf-1.0.2-py3-none-any.whl.

File metadata

  • Download URL: raven_pydf-1.0.2-py3-none-any.whl
  • Upload date:
  • Size: 88.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.6.1 requests/2.25.1 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.55.0 CPython/3.8.5

File hashes

Hashes for raven_pydf-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 f73821a7accb8d49a5bb222980557e54937600154cd7183dbd65088964aa801c
MD5 a8dc0688e1362efa441b4b44e9c032bd
BLAKE2b-256 19c2001ccf60b0fa677e6b8aaa698ed5b5fe3fd7d6a7891dfd2c42a00486117e

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page