Skip to main content

Categorical variable friendly pandas data frames

Project description

Quickstart

$ pip install dummipy

Let it out of the box…

from sklearn.linear_model import LinearRegression
from dummipy import cereal

type(cereal)
# CategoricalDataFrame

cereal.head()
reg = LinearRegression()
reg.fit(cereal[['mfr', 'vitamins', 'fat']], cereal.calories)

Installation

You’ll need `pandas <http://pandas.pydata.org/>`__, but any old version will do the trick. There is no pandas version pegged in the setup.py file so installing dummipy won’t mess up your existing sci-py setup.

$ pip install dummipy

Use

Just use it like any old data frame. That’s really all there is to it.

import dummipy as dp

df = dp.CategoricalDataFrame({
    "x": range(5),
    "y": ["a", "b", "c", "a", "b"]
})


df = pd.read_csv("foo.csv")
df = dp.CategoricalDataFrame(df)

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

dummipy-0.0.1.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

dummipy-0.0.1-py2.7.egg (8.9 kB view details)

Uploaded Source

File details

Details for the file dummipy-0.0.1.tar.gz.

File metadata

  • Download URL: dummipy-0.0.1.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for dummipy-0.0.1.tar.gz
Algorithm Hash digest
SHA256 fdc932d454f28fc1dba01428acd67a6a7562cd02b37ef78a3fdf8b51d86bb982
MD5 814bf4327c5a16472dddeca81a277c5a
BLAKE2b-256 e1eff803fadb53a33bd1796e889ff9733728d1a71a1988f6e8ce81f4d08baa27

See more details on using hashes here.

File details

Details for the file dummipy-0.0.1-py2.7.egg.

File metadata

  • Download URL: dummipy-0.0.1-py2.7.egg
  • Upload date:
  • Size: 8.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for dummipy-0.0.1-py2.7.egg
Algorithm Hash digest
SHA256 2485a9cc1a75170051ffd9fa53869a4e8607a881b71ba62a6cf70e2aacb4b562
MD5 2910314d9087f4e396075f87f866a543
BLAKE2b-256 3fe8bdc53fa9933f9c5dfb1e396999724c539902e6bcfcfef299d6ccd9b813db

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