CSV fill in the blank editor
Project description
FilMoreBlanks
CSV File fill-in-the-blank Editor
FilMoreBlanks take a CSV and parses it for a specific string and fills that value with a chosen value. This works from 1:1 to 1:many value swaps.
Getting started
- Place the CSV in the project main dir (for manual moves)
- fill out the config.yaml file that is located in the examples folder
- run the script using the quick start below
- POOF 💨
- you have a CSV that's just that much more useful to you
Files being moved
- processed files will move to the filled_files dir (Will be created in project path)
- the CSV used in the script will be moved to the archived dir (Will be created in project path)
- Config file will be moved to FilMoreBlanks_Configs (Will be created in project path)
Quick Start
# move the config file to the project dir when running (recommended)
python3 basic_access.py -config_file config.yaml
using as an import
when using as an import it will create a class object of the completed work, no config files are needed since it interacts with the main function directly.
pip install FilMoreBlanks
import pandas as pd
from FilMoreBlanks import blanket_fill
dat = pd.read_csv('test_csv.csv')
bf = blanket_fill.BlanketFill(df_data=dat)
config_dict = {
"new servers": [
'5,5,5,5',
'2.2.2.2',
'7,7,7,7'],
"11.1.0.0/16": [
"233.31.244.39",
"100.19.68.193",
'235.253.243.128',
'232.151.66.30',
'74.22.1.140'],
'169.156.158.231': [
'111.254.29.134',
'96.20.144.254']
}
affect_only_columns_dict = {'11.1.0.0/16':'source'}
bf.fix_csv(config_dict=config_dict,affect_only_columns_dict=affect_only_columns_dict)
res = bf.filled_data
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
FilMoreBlanks-1.1.0.tar.gz
(3.7 kB
view details)
Built Distribution
File details
Details for the file FilMoreBlanks-1.1.0.tar.gz
.
File metadata
- Download URL: FilMoreBlanks-1.1.0.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 69b7584db2b9013737175cfde3e55a7134e873958fdc3d1c225f4dd41c2c48bf |
|
MD5 | b080b5b685f591133f6f0978bb0c15cc |
|
BLAKE2b-256 | 25b1e7ae275d4739854eb0a4b9e3ad5d373e6a6aa66061ee5b548ef84945fc1e |
File details
Details for the file FilMoreBlanks-1.1.0-py3-none-any.whl
.
File metadata
- Download URL: FilMoreBlanks-1.1.0-py3-none-any.whl
- Upload date:
- Size: 4.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.11.1
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d34127bd1cd38f35db1b883709d182e6a26cca6e576c9eae631dd9a3e2da6c84 |
|
MD5 | 572e662ff13c7647dbc9720ee499d878 |
|
BLAKE2b-256 | 381e0a73dbd3c6d4b723f64d6f8a4e5d467ad4d59c8c3218c392a9c2827b51bb |