R script to create summary CSV files and diagrams from Flattr's Monthly Revenue reports. Example here. You can also flattr this repo:
- Download and install both RStudio and R.
- Go to your Flattr Transactions.
- Open each "Monthly revenue"-report (or start with only a few).
- Click "Download as CSV" below the table of Things.
- Save them to a folder of your choice.
- Download this repository to the same or any other folder and unpack the .zip.
- Open RStudio, copy-paste this command
install.packages(c("plyr", "ggplot2", "scales"))
into the console (bottom left) and run it by pressingReturn/Enter
. Some progress of new packages being installed should be visible. If an error is shown instead, copy-paste the error message into a search engine you don't completely distrust. - Once these packages are installed, open the script (.r file) in RStudio and run it with
alt + cmd + R
(Mac) orctrl + alt + R
(Win). - Follow its progress in RStudios'
Console
andPlot
tabs. This may take few seconds to several minutes, depending on your number of Flattr Revenue Reports, data points in them, and the speed of your computer. Example: 20 Reports with 200 data points at 2.3 GHz: 10-20sec. - Find the newly generated .csv files and .png diagrams in the same folder as the .csv files you downloaded from Flattr.
- Please report back :-) Are the diagrams useful? If not, at which dataset size? Which other summaries, calculations or diagrams would you find useful?
- sort data usefully DONE
- better file/folder selection DONE
- automatic download from flattr.com, including withdrawals & deposits
- draw more useful diagrams
- summarise Flattr clicks per month, not ordered by thing DONE
- predictions (anybody knows the statistics behind this?)
- episodes vs. other things (probably needs reg-ex on slugs)
- webapp via Shiny that processes given data
for a Flattr-clickNot a good idea - install on server to auto-run & publish diagram
- monthly_simple_plot contains statistical elements whose computation runs into errors if the number of Flattr Revenue Reports is below 5. Other graphs may also throw warnings. To avoid this while plotting such small datasets, insert
#
before any line withstat_
. Better yet: download more Revenue Reports, see2.
I try to follow the gitflow branching model. Therefore, please branch off develop
whenever possible, give the new branch a descriptive name and merge it back into develop
.
- Dr. Rick Scavetta of Science Craft and Konstanz Graduate School Chemical Biology for the Data Analysis course
- RegExr for help with finding regular expression
- R-help Archives of the ETH Zürich's Seminar For Statistics