Type: | Package |
Title: | R Shiny App for Creating Simplified Trial Summary (TS) Domain |
Version: | 0.1.4 |
Author: | Hanming Tu [aut, cre] |
Maintainer: | Hanming Tu <hanming.tu@gmail.com> |
Description: | Make it easy to create simplified trial summary (TS) domain based on FDA FDA guide https://github.com/TuCai/phuse/blob/master/inst/examples/07_genTS/www/Simplified_TS_Creation_Guide_v2.pdf. |
Depends: | R (≥ 3.0.1) |
License: | MIT + file LICENSE |
Encoding: | UTF-8 |
RoxygenNote: | 7.2.1 |
Suggests: | testthat |
Imports: | shiny, utils |
NeedsCompilation: | no |
Packaged: | 2022-08-27 20:53:25 UTC; htu |
Repository: | CRAN |
Date/Publication: | 2022-08-27 21:10:02 UTC |
Echo message
Description
This method displays or writes the message based on debug level. The filehandler is provided through environment variable 'log_fn', and the outputs are written to the file. This method will display message or a hash array based on debug level ('d_level'). If 'd_level' is set to '0', no message or array will be displayed. If 'd_level' is set to '2', it will only display the message level (lvl) is less than or equal to '2'. If you call this method without providing a message level, the message level (lvl) is default to '0'. Of course, if no message is provided to the method, it will be quietly returned. If 'd_level' is set to '1', all the messages with default message level, i.e., 0, and '1' will be displayed. The higher level messages will not be displayed.
Usage
echo_msg(prg, step, msg, lvl = 0, fn = NULL)
Arguments
prg |
program name calling from |
step |
step in the program |
msg |
the message to be displayed. No newline is needed in the end of the message. It will add the newline code at the end of the message. |
lvl |
the message level is assigned to the message. If it is higher than the debug level, then the message will not be displayed. |
fn |
log file name |
Value
message
Author(s)
Hanming Tu
Examples
NULL;
Check if a variable is na or null or space
Description
check if string or list is empty (na, null or blank spaces).
Usage
is_empty(x)
Arguments
x |
a list or string |
Value
true or false
Author(s)
Hanming Tu
Examples
is_empty(NULL);
is_empty('');
is_empty(NA);
Resolve absolute path
Description
Resolve absolute directory
Usage
resolve(dir, relpath)
Arguments
dir |
directory |
relpath |
relative path |
Author(s)
Hanming Tu
Examples
resolve("/Users/htu/myRepo", "scripts")
# get "/Users/htu/myRepo/scripts"
Start R Shiny app
Description
start R Shiny apps included in this package.
Usage
start_app(
app_name = "07_genTS",
n = 1,
pkg = "genTS",
pt = NULL,
lb = getOption("shiny.launch.browser", interactive()),
ht = getOption("shiny.host", "127.0.0.1"),
dm = "normal",
msg_lvl = NULL,
loc = "local"
)
Arguments
app_name |
app or script name |
n |
app number |
pkg |
package name |
pt |
Port number |
lb |
define the browser- shiny.launch.browser |
ht |
define the host or ip address |
dm |
display modes are auto, normal or showcase |
msg_lvl |
message level |
loc |
location of the scirpt: local|github; default to 'local' |
Author(s)
Hanming Tu
Examples
## Not run:
library(genTS)
start_appe() # default to "02_display"
start_app(1) # start "01_html"
## End(Not run)