8000 GitHub - LiosK/gncxml: gncxml - extract entries from GnuCash data file to pandas.DataFrame
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

LiosK/gncxml

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

74 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gncxml

PyPI

gncxml - extract entries from GnuCash data file to pandas.DataFrame

Installation

pip install gncxml

Usage (Command Line)

usage: gncxml [-h] [-l] [--csv] TYPE [FILE]

gncxml - print entries in GnuCash data file as data frame

positional arguments:
  TYPE        type of entries to print (account | commodity | price | split |
              transaction)
  FILE        GnuCash data file (XML format)

optional arguments:
  -h, --help  show this help message and exit
  -l, --long  list in long format
  --csv       print in csv format

Usage (Python Module)

import sys
import gncxml

try:
    book = gncxml.Book("mybook.gnucash")
except OSError as err:
    sys.exit(err)

# Extract splits as pandas.DataFrame
df = book.list_splits()
print(df[df["trn_date"] >= "2023-07-01"].to_csv())

See also: examples/module_usage.ipynb

License

Copyright 2017-2022 LiosK

Licensed under the Apache License, Version 2.0.

About

gncxml - extract entries from GnuCash data file to pandas.DataFrame

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

0