Learn R Programming

cran.stats (version 0.1)

plot_logs: Plot download stats.

Description

A dirty wrapper function to plot the download stats obtained by running stat_logs function.

Usage

plot_logs(dt)

Arguments

dt
A data.table that's obtained from running stat_logs function.

Details

At the moment, this is a dirty function. That is, it detects the column names and the number of columns to find out if dependency was set to TRUE or not. If the downloads for dependent packages doesn't exist, it plots just the total downloads for all the packages specified. If the column for downloads from dependent packages were present, it provides two plots (stitched together). The first one provides the number of times packages were downloaded directly (meaning not through dependencies), and the second one provides the number of downloads due to dependencies alone.

See Also

read_logs, stat_logs

Examples

Run this code
## Not run: 
# dt = read_logs(start = as.Date("2014-01-01"), 
#                end = as.Date("2014-01-31"), 
#                path = "./", dir="cran-mirror", 
#                verbose = TRUE)
# dt_s = stats_logs(dt)
# plot_logs(dt_s)
# ## End(Not run)

Run the code above in your browser using DataLab