package randomizeBE [🇷 for BE/BA]
❝ i want to opt the R Software. Please do help in this regards.
What about Google?
# Check whether the package is already installed,
# if not, get it form CRAN
package <- "randomizeBE"
inst <- package %in% installed.packages()
if (length(package[!inst]) > 0) install.packages(package[!inst])
library(randomizeBE) # attach it
help(package = randomizeBE) # the man-page
20 subjects, 2x2 crossover
RL4(n = 20, seqs = c("TR", "RT"))
Randomization table created: 2019-08-24 16:18:21
(seed: 1266635 blocksize: 4 )
subject seqno sequence
1 1 TR
2 2 RT
3 1 TR
4 2 RT
5 1 TR
6 2 RT
7 1 TR
8 2 RT
9 2 RT
10 1 TR
11 1 TR
12 2 RT
13 2 RT
14 2 RT
15 1 TR
16 1 TR
17 1 TR
18 1 TR
19 2 RT
20 2 RT
# another one (make the same call again)
Randomization table created: 2019-08-24 16:18:55
(seed: 7330240 blocksize: 4 )
subject seqno sequence
1 1 TR
2 1 TR
3 2 RT
4 2 RT
5 2 RT
6 2 RT
7 1 TR
8 1 TR
9 2 RT
10 1 TR
11 1 TR
12 2 RT
13 2 RT
14 2 RT
15 1 TR
16 1 TR
17 1 TR
18 2 RT
19 1 TR
20 2 RT
# reproduce the first one to make inspectors happy
RL4(n = 20, seqs = c("TR", "RT"), seed = 1266635)
Randomization table created: 2019-08-24 16:19:49
(seed: 1266635 blocksize: 4 )
subject seqno sequence
1 1 TR
2 2 RT
3 1 TR
4 2 RT
5 1 TR
6 2 RT
7 1 TR
8 2 RT
9 2 RT
10 1 TR
11 1 TR
12 2 RT
13 2 RT
14 2 RT
15 1 TR
16 1 TR
17 1 TR
18 1 TR
19 2 RT
20 2 RT
# 6-sequence Williams' design (one test and two references)
seqs <- sequences(design = "3x6x3", tmts = c("T", "R1", "R2"))
RL4(n = 18, seqs = seqs)
Randomization table created: 2019-08-24 16:20:10
(seed: 7330240 blocksize: 12 6 )
subject seqno sequence
1 6 R2R1T
2 2 R1R2T
3 1 TR1R2
4 5 R1TR2
5 4 TR2R1
6 6 R2R1T
7 2 R1R2T
8 3 R2TR1
9 5 R1TR2
10 1 TR1R2
11 4 TR2R1
12 3 R2TR1
13 4 TR2R1
14 2 R1R2T
15 6 R2R1T
16 5 R1TR2
17 1 TR1R2
18 3 R2TR1
# 2 group parallel
seqs <- suppressWarnings(sequences(design = "parallel"))
RL4(n = 20, seqs = seqs)
Randomization table created: 2019-08-24 16:20:28
(seed: 613450 blocksize: 4 )
subject seqno sequence
1 2 B
2 1 A
3 1 A
4 2 B
5 2 B
6 2 B
7 1 A
8 1 A
9 1 A
10 2 B
11 2 B
12 1 A
13 2 B
14 1 A
15 1 A
16 2 B
17 1 A
18 2 B
19 2 B
20 1 A
There is a glitch if
design = "parallel"
. Hence, I suppressed the warnings. Currently it is not possible to define treatments codes with e.g.
, tmts = c("T", "R")
. See Yung-jin’s post. Sooner or later Detlew will fix it.* ❝ Also want to know whether the regulatory accepts the randomization schedule generated by R as the most of the CRO's use SAS software for the same.
Regulators demand that the software is validated.1,2,3 Applicable to R, SAS as to any other (out of curiosity: How did you validate SAS’ PROC PLAN?). A goody4 and a quote from the FDA5
FDA does not require use of any specific software for statistical analyses, and statistical software is not explicitly discussed in Title 21 of the Code of Federal Regulations [e.g., in 21CFR part 11]. However, the software package(s) used for statistical analyses should be fully documented in the submission, including version and build identification.
- European Medicines Agency. GCP Inspectors Working Group. Reflection paper on expectations for electronic source data and data transcribed to electronic data collection tools in clinical trials. London, 9 June 2010. https://www.ema.europa.eu/en/documents/regulatory-procedural-guideline/reflection-paper-expectations-electronic-source-data-data-transcribed-electronic-data-collection_en.pdf
- International Council for Harmonisation. Integrated Addendum to ICH E6(R1): Guideline For Good Clinical Practice E6(R2). 9 November 2016. https://www.ich.org/fileadmin/Public_Web_Site/ICH_Products/Guidelines/Efficacy/E6/E6_R2__Step_4_2016_1109.pdf
- World Health Organization. Technical Report Series No. 996, Annex 9. Guidance for organizations performing in vivo bioequivalence studies (revision). Geneva, May 2016. https://www.who.int/medicines/publications/pharmprep/WHO_TRS_996_annex09.pdf
- The R Foundation for Statistical Computing. R: Regulatory Compliance and Validation Issues. A Guidance Document for the Use of R in Regulated Clinical Trial Environments. Vienna, March 25, 2018. free resource.
- US FDA. Statistical Software Clarifying Statement. May 6, 2015. Study Data Standards.
- See this post. Will take a couple of days until pre-compiled binaries will be available.
Dif-tor heh smusma 🖖🏼 Довге життя Україна!
Helmut Schütz
The quality of responses received is directly proportional to the quality of the question asked. 🚮
Science Quotes
Complete thread:
- Randomization Schedule in R sury 2019-08-23 13:39 [🇷 for BE/BA]
- package randomizeBEHelmut 2019-08-24 16:31
- package randomizeBE sury 2019-08-26 09:34
- package randomizeBE Helmut 2019-08-26 10:35
- package randomizeBE sury 2019-08-26 11:54
- (Pseudo-) random numbers, algos, seeds Helmut 2019-08-26 12:28
- how about randomly selected block sizes? yjlee168 2019-08-28 07:25
- how about randomly selected block sizes? ElMaestro 2019-08-28 09:26
- package randomizeBE sury 2019-08-26 11:54
- package randomizeBE Helmut 2019-08-26 10:35
- package randomizeBE sury 2019-08-26 09:34
- package randomizeBEHelmut 2019-08-24 16:31