Skip to content

Commit 000f9f1

Browse files
Katrin LeinweberKatrin Leinweber
authored andcommitted
qplot of monthly revenue
1 parent 429ccc7 commit 000f9f1

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

summarize-flattr-reports.R

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,13 +113,21 @@ flattr_plot <- ggplot(data = per_period_and_thing,
113113
complete = FALSE
114114
) # learned from http://docs.ggplot2.org/0.9.3/theme.html
115115
flattr_plot
116-
117116
ggsave(plot = flattr_plot,
118117
filename = "flattr-revenue-clicks.png",
119118
height = dim(per_period_and_thing)[1]/12, # number of things
120119
width = length(Flattr_filenames) # number of time points
121120
)
122121

122+
monthly_plot <- qplot(x = per_period$period,
123+
y = per_period$all_revenue,
124+
geom = "bar", stat = "identity", # have to be used together, or points are drawn instead of bars
125+
ylab = "Spendensumme [EUR]",
126+
xlab = NULL # learned from http://www.talkstats.com/showthread.php/54720-ggplot2-ylab-and-xlab-hell?s=445d87d53add5909ac683c187166c9fd&p=154224&viewfull=1#post154224
127+
)
128+
monthly_plot
129+
ggsave(plot = monthly_plot, filename = "flattr-revenue-months.png")
130+
123131

124132
# restore original working directory; useful if you use other scripts in parallel
125133
#setwd(original_wd)

0 commit comments

Comments
 (0)