RandIMI allows for participants of studies to be randomized. It implements a number of randomization algorithms with different guarantees.
More detailed documentation of RandIMI and its features can be found in the GitHub Wiki.
RandIMI currently supports the different randomization algorithms; blocked randomization, minimization, and randomization by tossing a coin.
Coin toss is the simplest for of randomization. A subject will simply be assigned to a random study arm.
Blocked randomization is more complicated, as it divides the randomization list into blocks to which the subjects will be assigned evenly, yet random. This guarantees that if a subset of subjects is selected, those are evenly distributed across the studies' strata.
Minimization is a more sophisticated randomization method that calculates an imbalance for all possible study arm assignments. By assigning the subject to the study arm that minimizes the imbalance, RandIMI ensures that the study arms are balanced in terms of subject characteristics, reducing potential biases.
RandIMI can be integrated into REDCap projects using the REDCap RandIMI Integration.
RandIMI can be installed using Docker. A docker-compose file is provided in the project's root directory.
-
Configure the
.envfile. Create a new.envfile and paste the content of the provided.env.examplefile into it. The only mandatory step is to set the database passwordPG_PASSWORD. -
Start the containers
docker-compose up -dBefore deploying RandIMI to a server, you need to install Java 17, Tomcat 10 and configure a PostgreSQL database.
Database name, user, and password can be chosen freely, but remember to change the values in the property file as well!
The file must be place in /etc/randimi/db.properties.
The application will create the required schema automatically.
Change the password of the admin account and configure the mail server. You should also adapt the content of the Imprint, Data Privacy, and Support popups.
Now RandIMI should be good to go to be built using mvn package from the project's root directory.
You can deploy RandIMI to the tomcat server by moving the war file inside the ./target directory to ~tomcat/webapps/.
- Install Java 17
- Install the latest PostgreSQL. If this fails, tested versions are: 15.1
- Install Tomcat 10
- Download Tomcat 10 Core from here: https://tomcat.apache.org/download-10
- Unzip the file and move the folder to your preferred destination
- Checkout RandIMI
- Set up the database. Execute the script
src/main/resources/db/db_create.sqlas user postgres - Add run configuration to your IDE
- IntelliJ
- Create a new configuration for a local Tomcat server
- Select the previous installed Tomcat 10 server as the
Application server. You might have to add the server by clicking theConfigure...button.Tomcat HomeandTomcat base directoryshould point to the extracted directory. - (Optional) Add
-Dspring.profiles.active=devto yourVM options. This enables hot reloading for frontend resources. - Select your
JRE - Under the
DeploymentTab add the artifactRandIMI.war explodedand set theApplication contextto your preferred value
- IntelliJ Community
- Install the plugin
Smart Tomcat - Select the previous installed Tomcat 10 server as the
Tomcat server. You might have to add the server by clicking theConfigure...button. - (Optional) Add
-Dspring.profiles.active=devto yourVM options. This enables hot reloading for frontend resources.
- Install the plugin
- IntelliJ
- (Optional) Install Docker for Selenium test
The user interface is being generated using thymeleaf, so the source code of all pages can be found in src/main/webapp/WEB-INF/views/.
Check out the thymeleaf documentation for more information.
During development, you may make changes to the database schema.
To ensure upgradability, RandIMI uses flyway for database migrations.
Instead of applying your changes to the database scheme directly, you should create a migration script in src/main/resources/db/migration/.
Although flyway keeps track of already applied migrations, it is best practice if the script itself checks if it is necessary to apply it, eg.
CREATE TABLE IF NOT EXISTS example...
Those scripts should be numbered and should not be modified once released.
RandIMI is licensed under the Apache-2.0 license.
RandIMI uses the following open-source libraries:
RandIMI was developed by the Medical Data Integration Center (MeDIC), Institute of Medical Informatics, University of Münster
Medical Data Integration Center (MeDIC)
Institute of Medical Informatics
University of Münster
Albert-Schweitzer-Campus 1, Gebäude A11
48149 Münster
medic@uni-muenster.de
0251 / 83 – 5 57 22
