Helper function for internal use to print formatted messages
when verbose = TRUE. It uses sprintf() for clean formatting.
.msg(...)Character strings passed to sprintf() for formatted output.
This function standardizes how verbose messages are displayed across
package functions. It automatically checks if a variable verbose
exists in the calling environment and is TRUE.
Use it inside functions like this:
n <- 5
verbose <- TRUE
.msg("Processing %d samples...", n)
If verbose is not defined or FALSE, no output is shown.