Read ?try, ?tryCatch, as well as the posting guide mentioned in the footer.
Andy > From: pastaska1934 > > hi, > i'm doing some bootstraping on a data set, using kmeans for > each bootstrap, > i mean i do a loop(200 times) and in each loop i use kmeans. > i have to count some occurences in a matrix result, > but somentimes kmeans fail, cause of the algorithm. > so i would like to avoid my function to stop on kmeans error > is there a way to do such a thing? > like > if(kmeans()=error)continue > or > if(kmeans != -1) go on > > thanks > > sebeuuuuuuuuuu^^ > > ______________________________________________ > [EMAIL PROTECTED] mailing list > https://www.stat.math.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide! > http://www.R-project.org/posting-guide.html > > ------------------------------------------------------------------------------ Notice: This e-mail message, together with any attachments,...{{dropped}} ______________________________________________ [EMAIL PROTECTED] mailing list https://www.stat.math.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html