Skip to content

sprintf crash (PR#2327)

2 messages · Thomas Lumley, stefano iacus

#
<snip>
Yes, that's because  missing.data$Hosp..No. isn't a string, it's a
factor.  In R 1.6.0 this gives an error rather than a crash.

You probably want

  sprintf("%s\t%1.0f", as.character(missing.data$Hosp..No.),
	missing.data$V1)



	-thomas
#
On Tuesday, November 26, 2002, at 05:46 PM, tlumley@u.washington.edu 
wrote:
yes, also

sprintf("%s\t%1.0f", levels(missing.data$Hosp..No.), missing.data$V1)

will work