Skip to main content

Drops duplicates in DataFrames with tedious dtypes

Tested against Windows / Python 3.11 / Anaconda

pip install dropduplicatesplanb

import pandas as pd
from dropduplicatesplanb import pd_add_drop_duplicates_planB

pd_add_drop_duplicates_planB()
df = pd.read_csv(
    "https://raw.githubusercontent.com/pandas-dev/pandas/main/doc/data/titanic.csv"
)


df["baba"] = df.Embarked.apply(lambda q: [q, q, q, q])
df.loc[0, "baba"] = [[[1, 2, 34, 4, 2, 2, 34, 2, 1]]]
df.loc[1, "baba"] = [[[1, 2, 34, 4, 2, 2, 34, 2, 1]]]
df = pd.concat([df for x in range(2)], ignore_index=True)
df21 = df.d_drop_duplicates_planB(subset="baba")
df32 = df.d_drop_duplicates_planB(subset=["PassengerId", "Survived"])
df43 = df.d_drop_duplicates_planB(subset=["PassengerId", "Survived"], keep="first")
df54 = df.d_drop_duplicates_planB()
print(df)
print(df21)
print(df32)
print(df43)
print(df54)

Metadata

Release files for dropduplicatesplanb 0.11

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dropduplicatesplanb 0.11
File Size Uploaded Provenance Actions
dropduplicatesplanb-0.11.tar.gz 20.9 kB Without provenance Details for dropduplicatesplanb-0.11.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for dropduplicatesplanb 0.11
File Interpreter ABI Platform Actions
dropduplicatesplanb-0.11-py3-none-any.whl Python 3 none any Details for dropduplicatesplanb-0.11-py3-none-any.whl

Total release size: 42.4 kB

Release files / dropduplicatesplanb-0.11.tar.gz

Download URL dropduplicatesplanb-0.11.tar.gz
Size 20.9 kB
Tags Source
SHA-256 checksum
How to use checksums
f332909e839455a272c183688e3747ad6c1dc73a1dab88393bf22959ceb75caf
BLAKE2b-256 checksum
How to use checksums
142ee98924dd993692a91e48197f8a296ec29a3d3d9aa5ae8526310823199d60
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.7

Release files / dropduplicatesplanb-0.11-py3-none-any.whl

Download URL dropduplicatesplanb-0.11-py3-none-any.whl
Size 21.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
2795c5605ddf94f69ae2b1e7392c75a5e60204d03f9d820fb662b4975ad3a6a8
BLAKE2b-256 checksum
How to use checksums
e9f801d9dc4f182099654dcf7ce8ec5b3f5ba27cda9b644d4b61179d73e095e5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.7

Security for dropduplicatesplanb 0.11

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.11 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page