The R Project SVN R

Rev

Rev 88550 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 88550 Rev 90049
Line 192... Line 192...
192
  point, so \code{formatC(c(6.11, 13.1), digits = 2, format = "fg")} gives
192
  point, so \code{formatC(c(6.11, 13.1), digits = 2, format = "fg")} gives
193
  \code{c("6.1", " 13")}.  If you want common formatting for several
193
  \code{c("6.1", " 13")}.  If you want common formatting for several
194
  numbers, use \code{\link{format}}.
194
  numbers, use \code{\link{format}}.
195
 
195
 
196
  \code{prettyNum} is the utility function for prettifying \code{x}.
196
  \code{prettyNum} is the utility function for prettifying \code{x}.
197
  \code{x} can be complex (or \code{\link{format}(<complex>)}), here.  If
197
  \code{x} can be complex (or \code{\link{format}(\var{complex})}), here.  If
198
  \code{x} is not a character, \code{format(x[i], ...)} is applied to
198
  \code{x} is not a character, \code{format(x[i], ...)} is applied to
199
  each element, and then it is left unchanged if all the other arguments
199
  each element, and then it is left unchanged if all the other arguments
200
  are at their defaults.  Use the \code{input.d.mark} argument for
200
  are at their defaults.  Use the \code{input.d.mark} argument for
201
  \code{prettyNum(x)} when \code{x} is a \code{character} vector not
201
  \code{prettyNum(x)} when \code{x} is a \code{character} vector not
202
  resulting from something like \code{format(<number>)} with a period as
202
  resulting from something like \code{format(\var{number})} with a period as
203
  decimal mark.
203
  decimal mark.
204
 
204
 
205
  Because \code{\link{gsub}} is used to insert the \code{big.mark}
205
  Because \code{\link{gsub}} is used to insert the \code{big.mark}
206
  and \code{small.mark}, special characters need escaping.  In particular,
206
  and \code{small.mark}, special characters need escaping.  In particular,
207
  to insert a single backslash, use \code{"\\\\\\\\"}.
207
  to insert a single backslash, use \code{"\\\\\\\\"}.