Thanks to visit codestin.com
Credit goes to github.com

Skip to content

cranlogs::cran_downloads() double counting 2023-09-19 through 2023-10-01 #68

@lindbrook

Description

@lindbrook

It seems that for the period between 2023-09-19 through 2023-10-01 cranlogs::cran_downloads() reports twice the number of package downloads than do the Posit/RStudio logs. Is it possible to recompute/fix these data?

dates <- seq.Date(as.Date("2023-09-15"), as.Date("2023-10-03"), by = "days")

Total Download Counts based on Posit/RStudio Logs:
logs <- lapply(dates, packageRank::fetchCranLog)
posit <- vapply(logs, nrow, integer(1L))

Total Download Counts based on cranlogs::cran_downloads():
rhub <- cranlogs::cran_downloads(from = min(dates), to = max(dates))

Audit:
audit <- data.frame(date = rhub$date, log.ct = posit, cranlogs.ct = rhub$count)
audit$ratio <- audit$cranlogs.ct / audit$log.ct

> audit
date log.ct cranlogs.ct ratio
1 2023-09-15 6479353 6479353 1
2 2023-09-16 3516904 3516904 1
3 2023-09-17 3534662 3534662 1
4 2023-09-18 7309822 7309822 1
5 2023-09-19 7608886 15217772 2
6 2023-09-20 7488178 14976356 2
7 2023-09-21 6862071 13724142 2
8 2023-09-22 6410593 12821186 2
9 2023-09-23 4011634 8023268 2
10 2023-09-24 3548594 7097188 2
11 2023-09-25 6845864 13691728 2
12 2023-09-26 7204419 14408838 2
13 2023-09-27 7188019 14376038 2
14 2023-09-28 6526022 13052044 2
15 2023-09-29 5653322 11306644 2
16 2023-09-30 3165387 6330774 2
17 2023-10-01 3277506 6555012 2
18 2023-10-02 6268556 6268556 1
19 2023-10-03 6732379 6732379 1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions