Variable names, lexical order? [Regulatives / Guidelines]
Hi David or Guo,
Done.
Correct so far.
In your example and the FDA’s code, yes and no. Alphanumeric codes are internally converted to factors in lexical order and integers by default. At least in all software I know. Examples in :
❝ 1. […] please change my username as "Weiguo21224" at your end.
Done.
❝ 2. I carefully reviewed previous discussion. My understanding is that "T" and "R" in FDA code do represent the "Test drug" and "Reference drug" respectively.
Correct so far.
❝ It should be:
❝
❝ ESTIMATE 'T (the large/later one in lexical order, Reference drug) vs. R (the small/early one in lexical order, Test drug') TRT 1 -1/CL ALPHA=0.1;
❝
❝ Right?
In your example and the FDA’s code, yes and no. Alphanumeric codes are internally converted to factors in lexical order and integers by default. At least in all software I know. Examples in :
trt <- as.factor(c("T", "R")) # T > R
print(trt); print(as.integer(trt))
[1] T R
Levels: R T
[1] 2 1
trt <- as.factor(c("Test", "Reference")) # Test > Reference
print(trt); print(as.integer(trt))
[1] Test Reference
Levels: Reference Test
[1] 2 1
trt <- as.factor(c("A", "B")) # A < B
print(trt); print(as.integer(trt))
[1] A B
Levels: A B
[1] 1 2
trt <- as.factor(c("tablet", "capsule")) # tablet > capsule
print(trt); print(as.integer(trt))
[1] tablet capsule
Levels: capsule tablet
[1] 2 1
R – T
instead of the desired T – R
.—
Dif-tor heh smusma 🖖🏼 Довге життя Україна!
Helmut Schütz
The quality of responses received is directly proportional to the quality of the question asked. 🚮
Science Quotes
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:
- ABE results from SAS and WinNolin are not matched weiguo2122 2023-04-19 14:43 [Regulatives / Guidelines]
- ABE results from SAS and WinNolin are not matched BEQool 2023-04-20 06:21
- Variable names, lexical order? Helmut 2023-04-20 08:13
- Variable names, lexical order? PharmCat 2023-04-20 19:58
- Variable names, lexical order? weiguo2122 2023-04-21 14:15
- Variable names, lexical order?Helmut 2023-04-21 15:45