Skip to content

Commit

Permalink
Update snippets.json
Browse files Browse the repository at this point in the history
  • Loading branch information
vrognas committed Sep 12, 2024
1 parent dccf8a0 commit aeba122
Showing 1 changed file with 39 additions and 37 deletions.
76 changes: 39 additions & 37 deletions snippets/snippets.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"prefix": "section",
"body": [
";; -----------------------------------------------------------------------------",
";; ${1:Section name}",
";; ${1:Section}",
";; -----------------------------------------------------------------------------",
""
],
Expand Down Expand Up @@ -195,8 +195,8 @@
"prefix": ["mu_reference"],
"body": [
"\n",
"MU_$1 = THETA($2) ; use theta on log-scale, not log(thetha)",
"TV$3 = MU_$4 + ETA($5)",
"MU_$1 = THETA($1) ; use theta on log-scale, not log(thetha)",
"TV$2 = MU_$1 + ETA($3)",
"\n$0"
],
"description": "MU referencing\n"
Expand All @@ -222,7 +222,7 @@
"\tOBASE = EXP(ODV) ; observed baseline response at time 0",
"ENDIF",
"IBASE = OBASE * EXP(ETA($1) * THETA($2)) ; observed baseline response, acknowledging the uncertainty with the same magnitude as RUV",
"A_0(X) = IBASE ; compartment initialization",
"A_0($3) = IBASE ; compartment initialization",
"\\$THETA (0, 0.3) ; RUV magnitude (sd)",
"\\$OMEGA 1 FIX ; IIV IBASE"
],
Expand All @@ -242,13 +242,14 @@
"BRV = EXP(ETA($4) * W * IIVW)",
"IBASE = (BPOP * RVW + OBASE * IIVW) * BRV ; individual baseline",
"A_0($5) = IBASE ; compartment initialization",
"$0",
"",
"; PUT BELOW IN \\$ERROR",
"IF (TIME == 0) THEN",
"\tIPRED = LOG(BPOP) + ETA($6) * IIV ; individual predicted baseline included to get an estimate of BPOP which is then used in the eq for IBASE",
"ELSE",
"\tIPRED = LOG(A(1))",
"ENDIF"
"ENDIF",
"$0"
],
"description": "Baseline as a covariate.\nSimilar to ”Gold standard” (B1).\nNo assumption about size of IIV vs RV (B3)\n"
},
Expand All @@ -261,9 +262,10 @@
";-----Baseline model-----------",
"IF (TIME == 0) IBASE = EXP(DV) ; observed baseline response",
"A_0($1) = IBASE ; compartment initialization",
"$0",
"",
"; PUT BELOW IN \\$ERROR",
"IPRED = LOG(A(1) / IBASE) ; the observations subsequent to the baseline observation are normalized by the baseline value."
"IPRED = LOG(A(1) / IBASE) ; the observations subsequent to the baseline observation are normalized by the baseline value.",
"$0"
],
"description": "Subtracting baseline (B4)\nLargest bias and imprecision.\nWith this method the baseline observation is subtracted from all subsequent measurements, alternatively all subsequent measurements are divided with the baseline observation.\nThe error in the baseline observations will be carried on to all subsequent observations.\nThe performance of this method will be better the smaller the residual error of the baseline observations\n"
},
Expand Down Expand Up @@ -309,21 +311,21 @@
"Boc-Cox transformation": {
"prefix": ["boxcox"],
"body": [
"BXPAR = THETA(2) ; Shape parameter",
"PHI = EXP(ETA(2)) ; Exponential transformation",
"ETATR = (PHI**BXPAR-1)/BXPAR ; Transformed eta",
"CL = TVCL*EXP(ETATR) ; Individual parameter"
"BXPAR = THETA($1) ; Shape parameter",
"PHI = EXP(ETA($2)) ; Exponential transformation",
"ETATR = (PHI**BXPAR - 1) / BXPAR ; Transformed eta",
"CL = TVCL * EXP(ETATR) ; Individual parameter"
],
"description": "Box-Cox transformation"
},
"t-distribution transformation": {
"prefix": ["tdist"],
"body": [
"DF = THETA(2) ; Degrees of freedom, t-distribution",
"DF = THETA($1) ; Degrees of freedom, t-distribution",
"; t-distribution transformed ETA",
"ETATR = ETA(1) * (1 + ((ETA(1)**2 + 1) / (4 * DF)) + &",
"((5 * ETA(1)**4 + 16 * ETA(1)**2 + 3) / (96 * DF**2)) + &",
"((3 * ETA(1)**6 + 19 * ETA(1)**4 + 17 * ETA(1)**2 - 15)/(384 * DF**3)))",
"ETATR = ETA($2) * (1 + ((ETA($2)**2 + 1) / (4 * DF)) + &",
"((5 * ETA($2)**4 + 16 * ETA($2)**2 + 3) / (96 * DF**2)) + &",
"((3 * ETA($2)**6 + 19 * ETA($2)**4 + 17 * ETA($2)**2 - 15)/(384 * DF**3)))",
"CL = TVCL * EXP(ETATR) ; Individual parameter"
],
"description": "t-distribution transformation"
Expand All @@ -332,18 +334,18 @@
"prefix": ["uniformdist"],
"body": [
"; A uniform parameter distribution between estimated values x and x+y",
"P_UNIF=THETA(1)+THETA(2)*PHI(ETA(1))",
"$THETA x ; 1",
"$THETA (0, y) ; 2",
"$OMEGA 1 FIX ; 1"
"P_UNIF=THETA($1)+THETA($2)*PHI(ETA($3))",
"\\$THETA x ; 1",
"\\$THETA (0, y) ; 2",
"\\$OMEGA 1 FIX ; 1"
],
"description": "uniform-distribution transformation"
},
"Hazard Exponential": {
"prefix": ["hazard_exponential"],
"body": [
"DADT($1) = SCALE",
"SUR = EXP(-A($2))"
"SUR = EXP(-A($1))"
],
"description": "Exponential hazard function\n"
},
Expand All @@ -353,7 +355,7 @@
"DEL = 1E-12",
"TIM = T + DEL",
"DADT($1) = SCALE * SHAPE * (SCALE * TIM)**(SHAPE - 1)",
"SUR = EXP(-A($2))"
"SUR = EXP(-A($1))"
],
"description": "Weibull hazard function\n"
},
Expand All @@ -363,7 +365,7 @@
"DEL = 1E-12",
"TIM = T + DEL",
"DADT($1) = SCALE * EXP(SHAPE * TIM)",
"SUR = EXP(-A($2))"
"SUR = EXP(-A($1))"
],
"description": "Gompertz hazard function\n"
},
Expand All @@ -378,7 +380,7 @@
"X1 = (LNT - MU) / SIGM",
"PDF = EXP(-0.5 * (X1**2)) / SQRT(2 * PI)",
"DADT($3)=1 / (TIM * SIGM) * PDF / (1 - PHI(X1))",
"SUR = EXP(-A($4))"
"SUR = EXP(-A($3))"
],
"description": "Log-normal hazard function\n"
},
Expand Down Expand Up @@ -497,7 +499,7 @@
"ENDIF",
"",
"\\$SIMULATION (12345) (678910 UNIFORM)",
"\n$0"
"$0"
],
"description": "Simulation from binary models"
},
Expand All @@ -507,7 +509,7 @@
"\n",
"\\$ESTIMATION METHOD=CONDITIONAL INTERACTION NOABORT MAXEVALS=99999 PRINT=1",
" NSIG=3 MCETA=0 RANMETHOD=4P SEED=1337 MSFO=$TM_FILENAME_BASE.msf",
"\n$0"
"$0"
],
"description": "FOCEI with sane defaults"
},
Expand All @@ -517,7 +519,7 @@
"\n",
"\\$ESTIMATION METHOD=IMP INTERACTION ISAMPLES=10000 NITER=10 PRINT=1",
" EONLY=1 RANMETHOD=3S2P SEED=1337",
"\n$0"
"$0"
],
"description": "IMP for OFV evaluation"
},
Expand All @@ -529,7 +531,7 @@
" ISAMPLE=1000 CTYPE=3 NITER=500 STDOBJ=10",
" ISAMPEND=10000 NOPRIOR=1 CITER=10 CINTERVAL=0",
" CALPHA=0.05 EONLY=0",
"\n$0"
"$0"
],
"description": "Options when setting AUTO=1 for DIRECT"
},
Expand All @@ -545,7 +547,7 @@
" PSAMPLE_M1=1 PSAMPLE_M2=-1 PSAMPLE_M3=1 OSAMPLE_M1=-1",
" OSAMPLE_M2=-1 OACCEPT=0.5 ISAMPLE_M1=2 ISAMPLE_M1A=0",
" ISAMPLE_M2=2 ISAMPLE_M3=3 ISAMPLE_M1B=2 MCETA=0",
"\n$0"
"$0"
],
"description": "Options when setting AUTO=1 for BAYES"
},
Expand Down Expand Up @@ -654,46 +656,46 @@
"",
"\\$TABLE ID TIME EVID MDV IPRED IRES IWRES CWRES",
"VARCALC=1",
"NOPRINT ONEHEADER FILE=sdtab$1 ; Standard table file",
"NOPRINT ONEHEADER FILE=sdtab${1:runno} ; Standard table file",
"",
"\\$TABLE ID CL V KA ETAS(1:LAST)",
"VARCALC=1",
"NOPRINT ONEHEADER FILE=patab$2 ; Model parameters - THETAs, ETAs and EPSes",
"NOPRINT ONEHEADER FILE=patab${1:runno} ; Model parameters - THETAs, ETAs and EPSes",
"",
"\\$TABLE ID AGE WT",
"NOPRINT ONEHEADER FILE=cotab$3 ; Continuous covariates",
"NOPRINT ONEHEADER FILE=cotab${1:runno} ; Continuous covariates",
"",
"\\$TABLE ID SEX",
"NOPRINT ONEHEADER FILE=catab$4 ; Categorical covariates",
"NOPRINT ONEHEADER FILE=catab${1:runno} ; Categorical covariates",
"\n$0"
],
"description": "Xpose-compatible TABLE records"
},
"csv": {
"prefix": ["format_csv"],
"body": ["FORMAT=,1PE15.8$0"],
"body": ["FORMAT=,1PE15.8"],
"description": "Format the NONMEM output into a comma separated file\nThe default is s1PE12.5.\nFirst character specifies delimiter (, s for space, or t for tab)\n1PE15.8 means E field notation, 15 total characters allotted to number, 8 digits beyond decimal point, 1 digits before decimal point"
},
"theta": {
"prefix": ["$THETA"],
"body": [
"\\$THETA (${1:-Inf}, ${2:0}, ${3:Inf}) ${4:FIX }; TV ${5:Description}",
"\\$THETA (${1:-Inf}, ${2:1}, ${3:Inf}) ${4:FIX} ; TV ${5:Description}",
"$0"
],
"description": "New THETA record"
},
"omega": {
"prefix": ["$OMEGA"],
"body": [
"\\$OMEGA (${1:-Inf}, ${2:0}, ${3:Inf}) ${4:FIX }; IIV ${5:Description}",
"\\$OMEGA (${1:-Inf}, ${2:0.9}, ${3:Inf}) ${4:FIX} ; IIV ${5:Description}",
"$0"
],
"description": "New OMEGA record"
},
"sigma": {
"prefix": ["$SIGMA"],
"body": [
"\\$SIGMA (${1:-Inf}, ${2:0}, ${3:Inf}) ${4:FIX }; RUV ${5:Description}",
"\\$SIGMA (${1:-Inf}, ${2:0.9}, ${3:Inf}) ${4:FIX} ; RUV ${5:Description}",
"$0"
],
"description": "New SIGMA record"
Expand Down

0 comments on commit aeba122

Please sign in to comment.