Skip to contents

With a ResearchBox API key set (see rbox_token()), each preregistration is read through ResearchBox's API, which serves AsPredicted's public preregistrations, with one request each. Without a key, or when the API fails, the preregistration's web page on AsPredicted is read instead; AsPredicted asks for a captcha after several pages, and no page is read after that.

Usage

aspredicted_info(ap_url, id_col = 1, wait = 1, cache = FALSE)

Arguments

ap_url

an AsPredicted URL, or a table containing them (e.g., as created by aspredicted_links())

id_col

the index or name of the column that contains AsPredicted URLs, if id is a table

wait

wait time in seconds after each web page read (the API's requests are spaced by ResearchBox's own limits)

cache

if TRUE, reuse a previously cached result for a preregistration already looked up (see repo_info_cache_clear()) instead of asking again. Off by default.

Value

a data frame of information

Details

Both routes give the same columns. Each answer is placed by the wording of its question, so both versions of AsPredicted's questions found so far (1.05 and 2.00) are read: version 1.05 asks about secondary analyses (AP_secondary) where version 2.00 asks about outliers (AP_outliers). An answer to a question that is not recognised is added to AP_anything_else, after its question. AP_created is the time of registration as AsPredicted shows it ("2021/06/14 02:17 (PT)") and AP_registered its date ("2021-06-14"). AP_number (AsPredicted's number), AP_status, AP_authors_count and AP_bundle (the numbers of the preregistrations registered together with this one) come from the API only, and are NA when the web page was read. From the API, AP_authors gives each author's name and university, without the e-mail address the web page shows.

A link that names no preregistration, such as AsPredicted's home page, is not looked up: its row has an error.

Examples

# \donttest{
if (online("aspredicted.org")) {
  aspredicted_info("https://aspredicted.org/blind.php?x=nq4xa3")
}
#> Starting AsPredicted retrieval for 1 file...
#> No ResearchBox API key is set, so AsPredicted preregistrations are read from AsPredicted's web pages. AsPredicted asks for a captcha after several pages, after which no more are read. Set a key with rbox_token() (make one at https://researchbox.org/api).
#> * Retrieving info from https://aspredicted.org/blind.php?x=nq4xa3...
#> ...AsPredicted retrieval complete!
#>                                       ap_url                          AP_title
#> 1 https://aspredicted.org/blind.php?x=nq4xa3 Depre_ctrl_elicit [3x2] [N800 MT]
#>   AP_authors            AP_created
#> 1       <NA> 2021/06/14 02:17 (PT)
#>                                               AP_data
#> 1 No, no data have been collected for this study yet.
#>                                                                                                                                                                                                                                                                                                  AP_hypotheses
#> 1 Participants will imagine a depressed person as more likely to be overweight, less likely to take care of themselves, less likely to be successful at work, with a less attractive face, and more introverted compared to an actor that is explicitly described as not depressed and to a control condition.
#>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       AP_key_dv
#> 1 Seven questions (all anchored at 1 = not at all and 7 = very much, with the exception of the introversion question which will be anchored at 1 = very introverted and 7 = very extroverted):\nDo you think this person is overweight?\nDo you think this person takes care of themselves?\nDo you think this person is successful at work?\nDo you think this person has an attractive face?\nDo you think this person is clinically depressed? (manipulation check)\nDo you think this person is introverted or extroverted?
#>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     AP_conditions
#> 1 Participants will be randomly assigned to one of six conditions, between-subjects, as two factors will be manipualated (target gender: male vs. female, and status: depressed vs. not depressed vs. control). first participants will be assigned to either the male or the female condition:\nMale condition:\nJonathan Smith is a bank clerk at LMS, a bank in New Orleans, Louisiana. He is originally from Houston, Texas. Jonathan is 38, has a Associate Degree in Management, and is Caucasian.\nFemale condition:\nJessica Smith is a bank clerk at LMS, a bank in New Orleans, Louisiana. She is originally from Houston, Texas. Jessica is 38, has a Associate Degree in Management, and is Caucasian.\nThen, participants will be assigned to the depression condition, the nondepression condition, or the control condition. Participants in the control condition will proceed to the questions without reading any additional text.\nParticipants in the depression condition will read this:\nThis person is clinically depressed. They often have insomnia and are in a state of a really bad mood.\nParticipants in the nondepression condition will read this:\nThis person is not depressed. They have their up and downs like everyone, but are overall quite OK psychologically speaking.
#>                                                                              AP_analyses
#> 1 We will conduct two-way ANOVAs with gender and condition as IVs and all the seven DVs.
#>                                                                                                                                                                                                                                                                                                                                                                                                                                                                        AP_outliers
#> 1 Participants who respond "Yes" to the question "Have you ever been on the planet Jupiter?" will be excluded from analyses.\n\n7) How many observations will be collected or what will determine sample size? No need to justify decision, but be precise about exactly how the number will be determined.\n800 Mturkers.\n\n8) Anything else you would like to pre-register? (e.g., secondary analyses, variables collected for exploratory purposes, unusual analyses planned?)
#>   AP_secondary AP_sample_size AP_anything_else AP_version AP_registered
#> 1         <NA>           <NA>             <NA>       2.00    2021-06-14
#>   AP_anonymous AP_number AP_status AP_authors_count AP_bundle
#> 1           NA      <NA>      <NA>               NA      <NA>
# }