Create beautiful graphs of your expenses in SettleUp
- Clone this repository:
git clone https://github.com/BurningKarl/SettleUpGraphs.git && cd SettleUpGraphs - Set up and activate your python environment:
pipenv install && pipenv shell - Use email export from SettleUp and put the
transactions.csvfile into the current folder - Run
python main.py - Open
SettleUpGraphs.htmlwith your web browser and view the generated graphs
Note: This tool makes use of the SettleUp categories, which is a paid feature at the moment. If you don't have this feature you can fill in your categories in the corresponding column in the CSV file and get the same result.
You can customize your output by using the commandline options:
-b bokehor-b pgfchanges the backend.
Whilebokeh, the default backend, produces an HTML file with the graphs you can see above,pgfproduces a PDF file with the help of LaTeX (example output). You will need a LaTeX installation to use it, see https://matplotlib.org/tutorials/text/pgf.html.-eor--emojisdisables translation of categories.
By default every category is translated from an emoji to its meaning. This is especially important for thepgfbackend, because LaTeX does not support emojis by default. If some of the emojis are not translated, you can either disable translation or add them to the correctemoji.{language}.ymlfile in the translations folder.-l LANGUAGEsets the language for translation.
The script tries to guess your language based on your systems locale settings, but you can also set it manually. The country codes areenordefor example and correspond to the files in the translations folder. If your language is not supported consider adding it and opening a pull request. The project uses https://pypi.org/project/python-i18n/ as the translation framework.-i INPUT_FILEand-o OUTPUT_FILEchanges the input and output files
The program expects the input to be atransactions.csvin the same folder as the script and outputs toSettleUpGraphs.htmlorSettleUpGraphs.pdf(depending on the backend) in this folder. If you want to use a different input file or want to save the output to a different location use the options above.
-
How do I restrict the graphs to a subset of all expenses?
Just remove the unecessary expenses from the CSV file but be sure to leave the header (first line) in otherwise the first expense will be ignored. -
How do I generate other graphs / a subset of these graphs?
The current graphs are hardcoded inside the{backend}_graphs.pyfiles, you would need to adapt those to your needs. -
How can I change the titles and category labels to be in my language
You need to add the command line option-l LANGUAGE, whereLANGUAGEis an abbreviated country code, e.g.en,deorfr, and make sure that the corresponding translations can be found intitles.{language}.ymlandemoji.{language}.ymlin thetranslationsfolder. -
Some categories are displayed as "emoji.{some emoji}" while others are correctly translated
The translations of the emojis can be found intranslations/emoji.{language}.yml. Edit the file corresponding to your language to add support for your custom emojis.
- The visualization library Bokeh
- The visualization library Matplotlib with the PGF backend
- The internationalization library
python-i18n


