Skip to main content

Extracts basic "Longest Consecutive Subsequences" features from a list of integers

Project description

Sequentiality

Introduction

https://pypi.org/project/sequentiality/0.0.1/

Sequentiality is a Python package designed for extracting key features from a list of integers. It specializes in identifying various forms of Longest Consecutive Subsequences (LCS) within an integer list. This functionality is crucial for data analysis, statistical assessments, and algorithmic processing in numerous fields.

Table of Contents

Installation & Importing

pip install sequentiality
from Sequentiality import Sequentiality

Features & Usage

Sequentiality provides methods for the following feature extraction capabilities:

  1. find_LongestConseqSubseq: Finds the Longest Consecutive Subsequence of integers in the list.
  2. find_LongestConseqSubseq_1gap: Identifies the LCS with one gap allowed.
  3. find_LongestConseqSubseq_2gap: Extracts the LCS allowing two gaps (only once between them).
  4. find_LongestConseqSubseq_from_end: Determines the LCS counted from the end of the list.
  5. find_LongestConseqSubseq_from_end_with_1_gap: LCS from the end with one gap allowed (only once).
  6. find_LongestConseqSubseq_from_end_with_2_gap: LCS from the end with two gaps allowed (specific conditions apply).

Additional utility methods:

  • find_sequential_elements_with_difference_of_2: Finds pairs in the sequence with a difference of 2.
  • find_sequential_elements_with_difference_of_3: Finds pairs in the sequence with a difference of 3.
seq = Sequentiality()
sample = [1, 2, 3, 4, 5, 7, 8, 10, 11, 12, 13, 16]
print(seq.find_LongestConseqSubseq(sample))
print(seq.find_LongestConseqSubseq_1gap(sample))
print(seq.find_LongestConseqSubseq_2gap(sample))
print(seq.find_LongestConseqSubseq_from_end(sample))
print(seq.find_LongestConseqSubseq_from_end_with_1_gap(sample))
print(seq.find_LongestConseqSubseq_from_end_with_2_gap(sample))

Documentation

https://github.com/karaposu/sequentiality

License

MIT License

Copyright (c) 2024 Enes Kuzucu

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

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

sequentiality-0.0.2.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

sequentiality-0.0.2-py3-none-any.whl (4.0 kB view details)

Uploaded Python 3

File details

Details for the file sequentiality-0.0.2.tar.gz.

File metadata

  • Download URL: sequentiality-0.0.2.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.7

File hashes

Hashes for sequentiality-0.0.2.tar.gz
Algorithm Hash digest
SHA256 0084e01a2eda3219ddbb3d9aea857083e22cd169433df51e427b266e9df079df
MD5 456d8f3b518b9950a5bea1a4787edce5
BLAKE2b-256 47c608cc5196df9e219e23ef1041fbadff042967dc56b5edf4f6f499996b4498

See more details on using hashes here.

File details

Details for the file sequentiality-0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for sequentiality-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9ac94bb5d86599a781ee2f8d5e40ef273002eb360b114cd04a16d6e91874db80
MD5 9d98e8351416edec848845a45dff3d94
BLAKE2b-256 5756cac55cd6722bf5d5bf8db311d43d42febb81c236bd039dea7f990be6211a

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