Main content

Home

Menu

Loading wiki pages...

View
Wiki Version:
**Repository** for Vogel, D., Reuber, A., & Vogel, R. (2020). Developing A Short Scale To Assess Public Leadership. *Public Administration*. Advance online publication. https://doi.org/10.1111/padm.12665 **!!! Due to a restrictive data privacy agreement with the participating organizations we are not able to publish the data used in this article. The provided data are synthetic data resembling the original data without violating participants’ privacy!!!** A **long-time archived** version of the data and code is available at https://zenodo.org/record/3716050 There is a **Code Ocean Capsule** for long-term computational reproducibility: https://doi.org/10.24433/CO.8236231.v1. See below for more information. ``Docker-Capsule.zip`` contains a **Docker image** that can be run locally and ensures long-term reproducibility. See below for more information. # Reproducibility ## Using Code Ocean You can easily reproduce our results using the free service of [Code Ocean][2]: 1. Open the paper's Code Ocean Capsule: https://doi.org/10.24433/CO.8236231.v1 2. Log-in to Code Ocean 3. Click *Re-Run* 4. Code Ocean runs a virtual environment and reproduces the results (with synthetic data). You can inspect the *R* code by clicking on the `Analysis_synthetic_data.R` file in the left panel (see below for an explanation of the file structure). You can also run an interactive version using Code Ocean. ## On your own machine (using your own *R* installation) If you want to reproduce our results on your own computer you need *R* (we used version 3.6.2) and RStudio. 1. Download the full OSF Storage of the Project (including `.here` and the folders `code`, `data`, `output` 2. Make sure that you installed all required packages (see below for a list of required packages) 3. Open `code/Analysis_synthetic_data.R` in RStudio. 4. Run the code ## On your own machine (using Docker) 1. Install Docker Community Edition 2. Download the `Docker-Capsule.zip` file 3. Open a Terminal and navigate to the extracted folder 4. Execute the following command: ```shell docker load --input Docker-Capsule.zip docker run --rm \ --workdir /code \ --volume "$PWD/data":/data \ --volume "$PWD/code":/code \ --volume "$PWD/results":/results \ capsule bash run ``` # File structure The repository consists of some files in the root folder and two folders. * `.here` is an empty file that helps the `here` package to set the right working directory in *R*. * `/data` contains the data of the paper in two CSV files: * `wave1_SYNTHETIC_DATA.csv`: Synthetic data of first wave * `wave2_SYNTHETIC_DATA.csv`: Synthetic data of second wave * `Codebook_wave1_SYNTHETIC_DATA.xlsx`: Codebook for data of first wave * `Codebook_wave2_SYNTHETIC_DATA.xlsx`: Codebook for data of second wave * `/code` contains the analysis script: * `Analysis_synthetic_data.R`: main file containing the analyses. * `/output` empty folder that stores the result of the analyses. # Required R packages * cocor * caTools * broman * stargazer * lavaan (0.6-5) * here * ltm * psych (1.9.12.31) * tidyverse (1.3.0) It is advised to use `R` version 3.6.2 with the `checkpoint` package and set the date to 2020-03-10 to ensure that the package versions are comparable: ```R library(checkpoint) checkpoint("2020-03-10") ``` [1]: https://mybinder.org [2]: https://codeocean.com [3]: https://mybinder.org
OSF does not support the use of Internet Explorer. For optimal performance, please switch to another browser.
Accept
This website relies on cookies to help provide a better user experience. By clicking Accept or continuing to use the site, you agree. For more information, see our Privacy Policy and information on cookie use.
Accept
×

Start managing your projects on the OSF today.

Free and easy to use, the Open Science Framework supports the entire research lifecycle: planning, execution, reporting, archiving, and discovery.