Saravanan666/pypi-org huggingface dataset:
Package: tablefile
tablefile package for python for reading a data file with multiple columns separated by space or any other characterInstall command:pip install tablefileUse example:from tablefile import *
f1=file("C:/Folder/SubFolder/data-file-name.txt","\t") # Last argument here specifies the column separator (here tab). 
#    or
f1=file("C:/Folder/SubFolder/data-file-name.txt") #If separator is blank or space (" ") one need not specify separator.

lines=f1.read() # or 'f1.read("l/c")'. This will read all the lines and store in 'lines' as list array
cols=f1.read("c/l")# Will read all the columns and store in 'cols' as list array
average=f1.read("av") # Calculates and stores column-wise average values in a list
sum=f1.read("sm") # Calculates and stores column-wise sum values in a list
std=f1.read("sd") # Calculates and stores column-wise standard deviation for a population in a list
stds=f1.read("sds") # Calculates and stores column-wise standard deviation for a sample in a list
min=f1.read("mn") # Calculates and stores column-wise minimum values in a list
max=f1.read("mx") # Calculates and stores column-wise maximum values in a list
print(lines[i][j]) # Prints column j element of line number i  (e.g. for 1st line i=0 and for 1st column j=0)
print(cols[i][j]) # Prints column i element of line number j  
print("Average=",average,"Sum=",sum,"Sigma_population=",std,"Sigma_sample=",stds,"Maximum=",max,"Minimum=",min)

# In the below operations the argument can be any 'list'
List_converted=convert(cols[0],'(x**2+sin(x))/2') # converts elements of a list by following any pre-defined expression
Value_sum=sm(cols[0]) # Summation of numeric elements. 
Value_av=av(cols[0]) # Average of numeric elements. 
Value_sd=sd(cols[0]) # Standard deviation of numeric elements. 
Value_sd_sample=sds(cols[0]) # Standard deviation of numeric elements. 
Value_mx=mx(cols[0]) # Maximum of numeric elements. 
Value_mn=mn(cols[0]) # Minimum of numeric elements. 
print(List_converted,Value_sum,Value_av,Value_sd,Value_sd_sample,Value_mx,Value_mn)

# **In all above cases Strings will be neglected during the calculation**For details please follow the linkhttps://www.respt.in/p/python-package-tablefile.html
Package: tablefill
背景在测试Web后台管理系统项目时，导入数据是个高频出现的功能，tablefill主要完成根据配置文件对模板进行填充数据使用安装pipinstalltablefill配置列数据类型[
  {
    "type": "faker", // 可选值 faker(默认值,可不写type这个字段)、input 会直接读取var 的值 由自己设置
    "func": "name", // 对应的是 Faker 生成虚拟数据的那些方法名 https://faker.readthedocs.io/en/master/providers.html
    "var": null, // 没有参数时可以不写该字段, 当type 为faker时 这部分会被作为func 对应函数名的入参
    "varFirst": "前", // 如果不需要可以不写该字段, 会在 var 这个 参数 前面 加上 内容
    "varEnd": "后" // 如果不需要可以不写该字段, 会在 var 这个 参数 后面 加上 内容
  }
]api参考fakerphone_number: 生成手机号
random_element: 列表中随机元素
name: 随机名称
ssn: 身份证号
date: 随机日期示例[{"type":"input","var":"这列我输入"},{"func":"phone_number"},{"func":"random_int","var":{"min":10,"max":21},"varFirst":"编号","varEnd":"班"},{"func":"random_element","var":{"elements":["小学","高中","初中"],}}]导入模板文件需要是xlsx/xls文件执行命令# --num 可选参数 默认 10条 ，这里就是30条fillgenerate配置文件模板文件生成文件名--num30fillgenerate"E:\coding\tablefill\examples\demo.json""E:\coding\tablefill\examples\demo.xlsx"demo.xls填充数据后的文件helpfill--help
Package: table-five
fifteen(DBAtable_five)Experimental library for quick quintet tallying, useful when you have a lot of quintets that somehow you don't want to count yourself.UsageBinary wheels are provided on PyPIpython3 -m pip install table_fiveAPITreeSetA treeset is an efficient (i.e., fast parsing) list of tree topologies. The construction is $O(k n \lg n)$ where $k$ is the number of trees and $n$ the number of taxa due to the LCA data structure initialization.fromtable_fiveimportTreeSettrees=TreeSet("path_to_newline_delimited_newicks.tre")Quintet CountingThe major API istally_sinlge_quintetreturning a list of length 15 containing the empirical
counts of the 15 ADR unrooted quintet topology among the tree-set in $O(k)$ time:# get counts of the ADR unrooted quintet topologies on taxa '1','2','3','4','5'. Taxa order matters.treeset.tally_single_quintet(('1','2','3','4','5'))# obviously you might want to convert it to numpy arrays# normalize by the number of genes in the tree-setnew_tree_dist=np.asarray(treeset.tally_single_quintet(q_taxa))/len(treeset)
Package: table-generator
Table GeneratorPython package for generating html code for tables from csv files.InstallationInstall Using gitIf you wish to run this file from the command line I suggest you use the scripts from the repo athttps://github.com/lol-cubes/table-generatorgitclonehttps://github.com/lol-cubes/table_generator.gitInstalll Using pippip install table_generatorUsage:generate_htmlArgs:file(str) - path to file containing csv tablecomplete_file(bool) -  whether or not to add html elements to make code function as a separate fileheader(bool) - whether or not to turn first row of csv values into<th>tagspretty(bool) - whether or not to prettify the output codeattrs(dict) - html attributes mapped to corresponding valuesExample usage:fromtable_generatorimportgenerate_htmlhtml_table=generate_html('data.csv',False,True,True,True,{"class":"table","id":"data-table"})
Package: tablelinker-lib
tablelinker-libTableLinker をコマンドライン / プログラム組み込みで利用するためのライブラリ。インストール手順Poetry を利用します。$ poetry install --with group=dev
$ poetry shellMacOS の場合、デフォルトの python バージョンが 3.11 なので
pytorch がインストールできません。以下の手順が必要です。% pyenv install 3.10
% poetry env use 3.10
% poetry shell
% poetry install --with group=devコマンドラインで利用する場合tablelinker モジュールを実行すると、標準入力から受け取った CSV を
コンバータで変換し、標準出力に送るパイプとして利用できます。$ cat sample/datafiles/yanai_tourism.csv | \
  python -m tablelinker sample/taskfiles/task.json利用するコンバータと、コンバータに渡すパラメータは JSON ファイルに記述し、
パラメータで指定します。組み込んで利用する場合sample.pyを参照してください。
Package: table-logger
TableLogger is a handy Python utility for logging tabular data into a console
or a text file with little overhead.Usagefromtable_loggerimportTableLoggertbl=TableLogger(columns='a,b,c,d')tbl(1,'Row1',datetime.now(),math.pi)tbl(2,'Row2',datetime.now(),1/3)tbl(3,'Row3',datetime.now(),random.random())Output:+----------------------+----------------------+---------------------+----------------------+
|                    a | b                    | c                   |                    d |
|----------------------+----------------------+---------------------+----------------------|
|                    1 | Row1                 | 2015-12-28 21:13:46 |    3.141592653589793 |
|                    2 | Row2                 | 2015-12-28 21:13:46 |    0.333333333333333 |
|                    3 | Row3                 | 2015-12-28 21:13:46 |    0.854212894923849 |Featuressane default formatting for basic python typesrow number, timestamp and time delta columnscsv outputallows to adjust column width and formatpython 2.7 and 3 supportInstallationPyPI:$ pip install table-loggerGitHub:$ git clone https://github.com/AleksTk/table-logger
$ cd table-logger
$ python setup.py installExamplesInclude row number, time-delta and timestamp columnstbl=TableLogger(columns='data',rownum=True,time_delta=True,timestamp=True)forein'abcde':time.sleep(random.randint(0,3))tbl(e)Output:+-----------+----------------------------+-----------------+----------------------+
|       row | timestamp                  |      time delta | data                 |
|-----------+----------------------------+-----------------+----------------------|
|         1 | 2016-01-01 21:40:35.956815 |     0.000000000 | a                    |
|         2 | 2016-01-01 21:40:35.957315 |     0.000000000 | b                    |
|         3 | 2016-01-01 21:40:37.957569 |     2.000253916 | c                    |
|         4 | 2016-01-01 21:40:37.957569 |     0.000500202 | d                    |
|         5 | 2016-01-01 21:40:39.958323 |     2.000253916 | e                    |Write to csv filewithopen('log.csv','wb')ascsvfile:tbl=TableLogger(file=csvfile,csv=True,columns='a,b')tbl('John "Smith"',1200000.890)tbl('Tommy,Cache',70000.125)Output:a,b
"John ""Smith""",1200000.890000
"Tommy,Cache",70000.125000Specify custom column widths and formatterstbl=TableLogger(columns='name,salary',float_format='{:,.2f}'.format,default_colwidth=15)tbl('John Smith',1200000.890)tbl('Tommy Cache',70000.125)Output:+-----------------+-----------------+
| name            |          salary |
|-----------------+-----------------|
| John Smith      |    1,200,000.89 |
| Tommy Cache     |       70,000.12 |
Package: tablemate
“Tablemate” is an easy-to-use Python package that takes tabular data
and pretty-prints it to the console, with Unicode or ASCII borders
and colors. There is a strict division between data and styling, and
the table layout takes account of the terminal geometry automatically.Besides producing fancy terminal output, the data can also be converted
into the usual serialization formats, and markup languages like html,
reStructuredText and markdown.With a static table layout, streaming is possible.Copyright ©  2015 Jürgen Hermann <jh@web.de>Licensed under the Apache License, Version 2.0 (the “License”);
you may not use this file except in compliance with the License.
You may obtain a copy of the License athttp://www.apache.org/licenses/LICENSE-2.0Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an “AS IS” BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Package: table-meta
Table MetaIt’s a universal class that created to be a middleware, universal mapping for data from different parsers - simple-ddl-parser and py-models-parser.Based on this middleware 2 libraries are worked - omymodels & fakeme.It’s allow create 1 adapter for different inputs and produce output only on one standard - easy to maintain ad add different output variants.All classes - Pydantic classes, so you can do with them anything that you can with Pydantic classes.Library contains 2 different classes - TableMeta - main class to convert input relative to models or tables. Second - Type, for Enum types data.How it useInstallpipinstalltable-metaUsagefromtable_metaimportTableMetadata={your_table_definition}table_data=TableMeta(**data)Convert simple-ddl-parser input to TableMetaSimple-ddl-parser:https://github.com/xnuinside/simple-ddl-parserPay attention that TableMeta expected data from simple-ddl-parser , that created with flag ‘group_by_type=True’
Example: result = DDLParser(ddl).run(group_by_type=True, output_mode=”bigquery”)To convert simple-ddl-parser output to TableMeta - use method: ddl_to_meta()Usage example:fromsimple_ddl_parserimportDDLParserfromtable_metaimportddl_to_metaddl="your ddl"parser_result=DDLParser(ddl).run(group_by_type=True,output_mode="bigquery")data=ddl_to_meta(parser_result)# ddl_to_meta returns Dict with 2 keys {"tables": [], "types": []} inside lists you will have Table Meta a modelsprint(data)Convert py-model-parser input to TableMetaPy-models-parser:https://github.com/xnuinside/py-models-parserUsage example:frompy_models_parserimportparsefromtable_metaimportmodels_to_metamodel_from="your python models, supported by parser"result=parse(model_from)data=models_to_meta(result)# models_to_meta returns Dict with 2 keys {"tables": [], "types": []} inside lists you will have a Table Meta modelsprint(data)Changelogv0.2.1Added support for parsing ‘dataset’ from data as ‘table_schema’ also added fields like ‘project’ (to support BigQuery metadata)Depencencies updatedAdded HQL Table Propertiesv0.1.5field ‘attrs’ added to Type to store values from py-models-parser outputv0.1.3‘parents’ added to Type and to Tablev0.1.1Fix dependencies for python 3.6v0.1.0Table Meta moved from O!MyModels to separate library. To make it re-usebale in fakeme library.
Package: tableMulti-anneeBiss
Le package tableMulti_anneeBiss contient deux modules "annee_bissextile" & "table_multiplication"le module annee_bissextile permet de verifier Ã  partir d'une annÃ©e entrer au clavier si elle est bissextile ou non.Le module table_multiplication permet d'afficher la table de multiplication en fonction d'un nombre enter au clavier.Vous pouvez l'installer avec pip:pip install tableMulti_anneeBissExemple d'usage:>>> from tableMulti_anneeBiss import annee_bissextile
>>> annee_bissextile()Ce code est sous licence WTFPL.
Package: table-nan-val
Table_Nan_ValCheck the missing value in Data FrameInstallationpip install table-nan-valHow to use it?import table_nan_val as tnvtnv.Missing_Value_Analysis(df)then you will get analysis table and graphLicensecopyright @ 2021 BDFDThis repository is licensed under the MIT license. See LICENSE for details.Referenceshttps://github.com/bdfd/6.1-PyPI_Table_Nan_Val
Package: tableofcontents
tocGenerate a table of contents from the comments of a fileWhat is it?tocis a command line utility that generates the table of contents of a file from a special kind of comments.Think it as atreefor the contents of a file, instead of a directory.Why should I use it?Few reasons that you may consider:it can make your files understandable in seconds, even if you haven't touched them for a whileyou can jump directly to the section you need to edit, because you know where it's locatedit makes you reflect about the structure of your file, making it more logicalfor software developers, it makes your code base more readable to othersHow does it work?First, you have to write the comments representing the different sections of a file.
Second, you runtocon that file to turn those comments into a table of contents.Comments are structured in this way:By runningtoc file.c, you will read the table of contents of that fileThis table of contents of that file can also be embedded in the original file withtoc -f file.cHow can I use it?First, you needPythoninstalled in your system.Then, you can install toc by running:pipinstalltableofcontentsIf you are using Arch or Manjaro Linux, you can installtocdirectly from the AUR.You should now be able to runtoc -hto display a list of parameter you can use.SeeUSAGE.mdfor step-by-step explanations of different features, and a list of languages supported natively (e.g. Markdown, AsciiDoc, reStructuredText) or that need special attention (e.g. CSS)Seehttps://regex101.com/r/ngzZXN/1for examples of valid and invalid comments.How can I contribute?SeeCONTRIBUTING.mdWhat has changed from previous versions?SeeCHANGELOG.md
Package: tableparse
TableparseA stand alone library which parses an array and a set of headers into a text based tableFeaturestableparse.tablify(2D array of strings)
Takes a 2D array of strings and returns a string containing the tablee.g.>>> array = [>>> ["Title","Description"],>>> ["Macbeth","A play by Shakespear"]>>> ]>>> print(tableparse.tablify(array))
╔═══════╦═════════════════════╗
║Title  ║Description          ║
╠═══════╬═════════════════════╣
║Macbeth║A play by Shakespeare║
╚═══════╩═════════════════════╝Usageimporttableparsearray=[["Name","Description","URL"],["TableParse","A stand alone table generators","https://github.com/TommyGymer/Tableparse"],["JSChess","A stand alone JS chess implementation","https://github.com/TommyGymer/JS-Chess"],["Dijkstra Pathfinding","An implementation of Dijkstra's pathfinding algorithm","https://github.com/TommyGymer/Dijkstra-pathfinding"]]result=tableparse.tablify(array)tablifyTurns a 2D array into a table stringtablify_strlength=2000result=tableparse.tablify_str(array,length)Returns a list of strings containing a table split in the 'length' charactersinv_arrayinv_array=tableparse.inv_array(array)result=tableparse.tablify(inv_array)Flips an array's columns and rows
Package: tableParser
TableParsertableParser is a python program using the concept of deep learning for extract the data from tables present in the PDF. It basically takes the file name of the pdf and extrcts the tables from the PDF. This is usefull when we need tables of the reserch papers or some thing like long table. This program uses the pytorch framework (made by facebook) and tesseract for parsing the table data.This is an Intital stage of the project. It have some bugs hopefully later release will fix this issue. 😊
Package: tableplus-macos-update-creds
tableplus-macos-update-credsA python library to update credentials for a connection in TablePlus macOS client without using GUITablePlusis a neat SQL GUI client. As virtually any decent SQL client it allows juggling
multiple connections, storing the credentialsin a secure manner. However, updating
a lot of ephemeral credentials via GUI may be somewhat annoying even though importing connectionsis supported.This library's main goal is to allow updating credentials programmatically, without using GUI.Please note that this project is not affiliated with TablePlus and all the techniques have been developed through (poor)
reverse engineering. The library has only been tested against TablePlus 4.2.0 (build 388) on macOS 13.1 with python
3.7/3.8/3.9/3.10. The techniques employed may stop working if any of these happens:TablePlus changes its connections config formatmacOS changes ACL mechanicsExampleThe following code may be used as a shell script#!/usr/bin/env python3

from argparse import ArgumentParser
import sys

from tableplus_macos_update_creds import update_creds


def main():
    parser = ArgumentParser()
    parser.add_argument('--connection', dest='connection')
    parser.add_argument('--username', dest='username')
    parser.add_argument('--password', dest='password')
    args = parser.parse_args(sys.argv[1:])

    update_creds(args.connection, username=args.username, password=args.password)


if __name__ == '__main__':
    main()
Package: table_printer
DescriptionPrint a list of python dicts as an organized table.The code is mostly copied fromthisStack Overflow comment
with the following additions: - customization of the top and bottom line
characters - customization of the alignment (‘left’ or ‘right’) -
automatic truncation of text that is longer than the column width with
ellipses (’…’) - ability to receive a separate data set that will be
printed as a totals row at the bottom of the table by passing optional
argumentInstallationpip install table_printerUsagefrom table_printer import TablePrinter

fmt = [
  ('Title',         'title',        50, 'left'),
  ('Description',   'description',  50, 'right'),
]
data = [{'title': 'Hello', 'description': 'World'}]
totals = {'title': 'TOTAL', '1 title'}
print TablePrinter(fmt, sep='|', ul='=', tl='-', bl='_')(data, totals)Output--------------------------------------------------|--------------------------------------------------
Title                                             |                                       Description
==================================================|==================================================
Hello                                             |                                             World
==================================================|==================================================
TOTAL                                             |                                           1 title
__________________________________________________|__________________________________________________See table_printer/table_printer.py for additional arguments and
details.
Package: tablepy-lib
tablepy LibThis is a versatile and user-friendly Python table library that can quickly render any Dictionary{key, []} or DataFrame into a visually appealing markdown or sql insertDownload Statshttps://pypistats.org/packages/tablepy-libNotebook for testinghttps://github.com/JordiCorbilla/tablepy-lib/blob/main/Test%20Package.ipynbUsage: Output as Markdown/consolefromtablepy_libimportmarkdowndata={"Name":["John","Emily","Tom","JC"],"Age":[-28,3002.6,25,2],"Country":["USA","Canada","UK","DE"],"Data":["USA","Canada","UK","3434243"]}table=markdown(data)print(table)Sample output:| Name    | Age      | Country   | Data      | 
| ------- | -------- | --------- | --------- | 
| John    | -28.0    | USA       | USA       | 
| Emily   | 3002.6   | Canada    | Canada    | 
| Tom     | 25.0     | UK        | UK        | 
| JC      | 2.0      | DE        | 3434243   |NameAgeCountryDataJohn-28.0USAUSAEmily3002.6CanadaCanadaTom25.0UKUKJC2.0DE3434243Usage: Output as SQL Insertfromtablepy_libimportsql_insertdata={"Name":["John","Emily","Tom","JC"],"Age":[-28,3002.6,25,2],"Country":["USA","Canada","UK","DE"],"Data":["USA","Canada","UK","3434243"]}data_frame=pd.DataFrame(data)table=sql_insert(data_frame,'dd')print(table)Sample output:INSERTINTOdd(Name,Age,Country,Data)VALUES('John',-28.0,'USA','USA');INSERTINTOdd(Name,Age,Country,Data)VALUES('Emily',3002.6,'Canada','Canada');INSERTINTOdd(Name,Age,Country,Data)VALUES('Tom',25.0,'UK','UK');INSERTINTOdd(Name,Age,Country,Data)VALUES('JC',2.0,'DE',3434243);
Package: tableqa
tableQATool for querying natural language on tabular data like csvs,excel sheet,etc.FeaturesSupports detection from multiple csvsSupports FuzzyString implementation. i.e, incomplete csv values in query can be automatically detected and filled in the query.Open-Domain, No training required.Add manual schema for customized experienceAuto-generate schemas in case schema not providedData visualisationsConfiguration:install via pip:pip install tableqainstalling from source:git clone https://github.com/abhijithneilabraham/tableQAcd tableqapython setup.py installQuickstartDo sample queryfrom tableqa.agent import Agent
agent=Agent(df) #input your dataframe
response=agent.query_db("Your question here")
print(response)Get an SQL query from the questionsql=agent.get_query("Your question here")  
print(sql) #returns an sql queryAdding Manual schemaSchema Format:{
    "name": DATABASE NAME,
    "keywords":[DATABASE KEYWORDS],
    "columns":
    [
        {
        "name": COLUMN 1 NAME,
        "mapping":{
            CATEGORY 1: [CATEGORY 1 KEYWORDS],
            CATEGORY 2: [CATEGORY 2 KEYWORDS]
        }

        },
        {
        "name": COLUMN 2 NAME,
        "keywords": [COLUMN 2 KEYWORDS]
        },
        {
        "name": "COLUMN 3 NAME",
        "keywords": [COLUMN 3 KEYWORDS],
        "summable":"True"
        }
    ]
}Mappings are for those columns whose values have only few distinct classes.Include only the column names which need to have manual keywords or mappings.Rest will will be autogenerated.summableis included for Numeric Type columns whose values are already count representations. Eg.Death Count,Casesetc. consists values which already represent a count.Example (with manual schema):Database queryfrom tableqa.agent import Agent
agent=Agent(df,schema) #pass the dataframe and schema objects
response=agent.query_db("how many people died of stomach cancer in 2011")
print(response)
#Response =[(22,)]SQL querysql=agent.get_query("How many people died of stomach cancer in 2011")
print(sql)
#sql query: SELECT SUM(Death_Count) FROM cancer_death WHERE Cancer_site = "Stomach" AND Year = "2011"Multiple CSVsPass the absolute path of the directories containing the csvs and schemas respectively. Refercleaned_dataandschemafor examples.Examplecsv_path="/content/tableQA/tableqa/cleaned_data"
schema_path="/content/tableQA/tableqa/schema"
agent=Agent(csv_path,schema_path)Join usJoin our slack workspace:Slack
Package: tabler
What is tabler?Tabler allows you to quickly and easily open, edit, create and update common
files that hold data in a tabulated format, such as CSV or XLSX files. It’s
simple API keeps your source code clean and allows easy use of an interactive
session.It can:Access spreadsheet files.Update text in cells.Write spreadsheet files.Compatible formats:.csvOpen Spreadsheet Format .odsMicrosoft Excel .xlsxHTML (Write only)It can be extended to open other file types.The full documentation is available onRead the Docs.Tabler lives onGitHub.ContactPlease send all comments and queries to Luke Shiner atluke@lukeshiner.com.Issues can be reported onGitHub.LicenseDistributed with MIT License.CreditsCreated by Luke Shiner (luke@lukeshiner.com)