mytable-lucien


Namemytable-lucien JSON
Version 6.0.0 PyPI version JSON
download
home_pagehttps://github.com/lucienshawls/mytable-lucien
SummaryA simple package for processing data in the form of a table.
upload_time2022-08-06 07:12:36
maintainer
docs_urlNone
authorLucien
requires_python
license
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Package `mytable-lucien`
A simple package for processing data in the form of a table.

Pay attention, *all indexes start from 0 instead of 1*.

To install:
```shell
pip install mytable-lucien
```
To import:
```python
import mytable_lucien
```
## Module `mycsv`
This is a simple reader and writer for CSV files by Lucien Shaw. It consumes less resource and processes more quickly than the current csv module, though a lot less functional.

It reads CSV files as plain texts and stores the table in a list, whose elements are lists of cells of the current row. The list is the value to the key 'full' of a dict, which is the returned value of the function.

Here is the guidance.
### Import
```python
from mytable_lucien import mycsv
```
### Function `read()`
This reads a CSV file and store the table in a list.
- Usage
  ```python
  res = mycsv.read(filename, delimiter=',')
  ```
- Arguments
  - `filename`  
    A string value. The filename of the CSV file.
  - `delimiter`  
    A char value. Comma by default. The character which is used to delimit the columns.
- Returned value  
  List of rows. Each row is a list of columns, aka. cells, which contains strings. 
### Function `write()`
This creates a CSV file.
- Usage
  ```python
  mycsv.write(filename, table, delimiter=',')
  ```
- Arguments
  - `filename`  
    A string value. The filename of the CSV file to be written.
  - `table`  
    A list, the structure of which is the same as the value to the key 'full' of the returned dict of function read().  
    All values should be **string**s.
  - `delimiter`  
    A char value. Comma by default. The character which is used to delimit the columns.
- Returned value  
  There are no returned values.
## Module `mytools`
Useful tools. Simple, yet powerful.
### Import
  ```python
  from mytable_lucien import mytools
  ```
### Function `excel_ctn()`
All functions of this package use numbers as indexes, but Excel uses alphabets as indications of the columns, such as 'A' for column 0 (*We count from 0, remember?*), 'Z' for column 25, and 'AA' for column 26.

This converts the alphabetical column Characters To pure Numbers.
- Usage
  ```python
  res = mytools.excel_ctn(col)
  ```
- Arguments
  - `col`  
    Alphabetical column characters, such as 'A' or 'AA', etc.
- Returned value  
  A number, as mentioned above.
## Module `myview`
This provides a better view of the tables.
### Import
```python
from mytable_lucien import myview
```
### Function `select_range()`
In some circumstances, there are so many columns that they cannot be fully displayed in excel, and columns that exceed the limit cannot be visualized.

This allows you to select some columns and rows so that you can extract them to a new temporary CSV file and view them with your favorite table viewer, like Excel.
- Usage
  ```python
  table_select = myview.select_range(table, columns=[], rows=[])
  ```
- Arguments
  - `table`  
    An original table in the form of a list.
  - `columns`  
    A list of column numbers that indicate the columns you would like to see. The default value is an empty list, which selects all columns.
  - `rows`  
    A list of row numbers that indicate the rows you would like to see. The default value is an empty list, which selects all rows.
- Returned value  
  A table which contains the selected range. 
## Module `myedit`
Edit the table the easy way.
### Import
```python
from mytable_lucien import myedit
```
### Function `combine_rows()`
This combines rows of multiple tables with the same total number of columns.
- Usage
  ```python
  comb = myedit.combine_rows(tables)
  ```
- Arguments
  - `tables`  
    A list which contains multiple tables.
- Returned value  
  The combined table.
### Function `combine_columns()`
This combines columns of multiple tables with the same total number of rows.
- Usage
  ```python
  comb = myedit.combine_columns(tables)
  ```
- Arguments
  - `tables`  
    A list which contains multiple tables.
- Returned value  
  The combined table.



            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/lucienshawls/mytable-lucien",
    "name": "mytable-lucien",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "",
    "author": "Lucien",
    "author_email": "myxlc55@outlook.com",
    "download_url": "https://files.pythonhosted.org/packages/80/4a/7112649b7205cdd065567cdb9aa7bf99ec0260baecbbad526eb585d0f6a4/mytable-lucien-6.0.0.tar.gz",
    "platform": null,
    "description": "# Package `mytable-lucien`\nA simple package for processing data in the form of a table.\n\nPay attention, *all indexes start from 0 instead of 1*.\n\nTo install:\n```shell\npip install mytable-lucien\n```\nTo import:\n```python\nimport mytable_lucien\n```\n## Module `mycsv`\nThis is a simple reader and writer for CSV files by Lucien Shaw. It consumes less resource and processes more quickly than the current csv module, though a lot less functional.\n\nIt reads CSV files as plain texts and stores the table in a list, whose elements are lists of cells of the current row. The list is the value to the key 'full' of a dict, which is the returned value of the function.\n\nHere is the guidance.\n### Import\n```python\nfrom mytable_lucien import mycsv\n```\n### Function `read()`\nThis reads a CSV file and store the table in a list.\n- Usage\n  ```python\n  res = mycsv.read(filename, delimiter=',')\n  ```\n- Arguments\n  - `filename`  \n    A string value. The filename of the CSV file.\n  - `delimiter`  \n    A char value. Comma by default. The character which is used to delimit the columns.\n- Returned value  \n  List of rows. Each row is a list of columns, aka. cells, which contains strings. \n### Function `write()`\nThis creates a CSV file.\n- Usage\n  ```python\n  mycsv.write(filename, table, delimiter=',')\n  ```\n- Arguments\n  - `filename`  \n    A string value. The filename of the CSV file to be written.\n  - `table`  \n    A list, the structure of which is the same as the value to the key 'full' of the returned dict of function read().  \n    All values should be **string**s.\n  - `delimiter`  \n    A char value. Comma by default. The character which is used to delimit the columns.\n- Returned value  \n  There are no returned values.\n## Module `mytools`\nUseful tools. Simple, yet powerful.\n### Import\n  ```python\n  from mytable_lucien import mytools\n  ```\n### Function `excel_ctn()`\nAll functions of this package use numbers as indexes, but Excel uses alphabets as indications of the columns, such as 'A' for column 0 (*We count from 0, remember?*), 'Z' for column 25, and 'AA' for column 26.\n\nThis converts the alphabetical column Characters To pure Numbers.\n- Usage\n  ```python\n  res = mytools.excel_ctn(col)\n  ```\n- Arguments\n  - `col`  \n    Alphabetical column characters, such as 'A' or 'AA', etc.\n- Returned value  \n  A number, as mentioned above.\n## Module `myview`\nThis provides a better view of the tables.\n### Import\n```python\nfrom mytable_lucien import myview\n```\n### Function `select_range()`\nIn some circumstances, there are so many columns that they cannot be fully displayed in excel, and columns that exceed the limit cannot be visualized.\n\nThis allows you to select some columns and rows so that you can extract them to a new temporary CSV file and view them with your favorite table viewer, like Excel.\n- Usage\n  ```python\n  table_select = myview.select_range(table, columns=[], rows=[])\n  ```\n- Arguments\n  - `table`  \n    An original table in the form of a list.\n  - `columns`  \n    A list of column numbers that indicate the columns you would like to see. The default value is an empty list, which selects all columns.\n  - `rows`  \n    A list of row numbers that indicate the rows you would like to see. The default value is an empty list, which selects all rows.\n- Returned value  \n  A table which contains the selected range. \n## Module `myedit`\nEdit the table the easy way.\n### Import\n```python\nfrom mytable_lucien import myedit\n```\n### Function `combine_rows()`\nThis combines rows of multiple tables with the same total number of columns.\n- Usage\n  ```python\n  comb = myedit.combine_rows(tables)\n  ```\n- Arguments\n  - `tables`  \n    A list which contains multiple tables.\n- Returned value  \n  The combined table.\n### Function `combine_columns()`\nThis combines columns of multiple tables with the same total number of rows.\n- Usage\n  ```python\n  comb = myedit.combine_columns(tables)\n  ```\n- Arguments\n  - `tables`  \n    A list which contains multiple tables.\n- Returned value  \n  The combined table.\n\n\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "A simple package for processing data in the form of a table.",
    "version": "6.0.0",
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "7b1b9c132c0a89a27b477fe2e1c3ea55",
                "sha256": "904990c40d5258e855ab4060d14b2c88aa8cbe42e90fcd69e8895c9adf8a892b"
            },
            "downloads": -1,
            "filename": "mytable_lucien-6.0.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "7b1b9c132c0a89a27b477fe2e1c3ea55",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 5826,
            "upload_time": "2022-08-06T07:12:35",
            "upload_time_iso_8601": "2022-08-06T07:12:35.118642Z",
            "url": "https://files.pythonhosted.org/packages/70/58/c9fe5a2e9738699cfe7a31d1af6797ccf2f8b7aaa9b2515e6b03c6c196e2/mytable_lucien-6.0.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "9c287c1b06fcf6b71a9af7f68f699ca7",
                "sha256": "5953369c8ac66a32ccfc751ebfae1e15eddccd1aea6831fd0a366f1b97bfb935"
            },
            "downloads": -1,
            "filename": "mytable-lucien-6.0.0.tar.gz",
            "has_sig": false,
            "md5_digest": "9c287c1b06fcf6b71a9af7f68f699ca7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 4744,
            "upload_time": "2022-08-06T07:12:36",
            "upload_time_iso_8601": "2022-08-06T07:12:36.192349Z",
            "url": "https://files.pythonhosted.org/packages/80/4a/7112649b7205cdd065567cdb9aa7bf99ec0260baecbbad526eb585d0f6a4/mytable-lucien-6.0.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2022-08-06 07:12:36",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "lucienshawls",
    "github_project": "mytable-lucien",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "mytable-lucien"
}
        
Elapsed time: 0.46313s