im using plclust and want the labels to be different colors. i took a look at getS3method("plot","hclust") and saw a call to .Internal. i looked at the help on .Internal and dont know where to go next. any help appreciated! thanks, rafael
On Fri, 2 Jul 2004, Rafael A. Irizarry wrote:> im using plclust and want the labels to be different colors. > i took a look at getS3method("plot","hclust") > and saw a call to .Internal. i looked at the help on .Internal and dont > know where to go next. any help appreciated!The R source code, specifically src/main/names.c which maps the .Internal named call to C calls. In your case the lines {"dend", do_dend, 0, 111, 6, {PP_FUNCALL, PREC_FN, 0}}, {"dend.window", do_dendwindow, 0, 111, 5, {PP_FUNCALL, PREC_FN, 0}}, and gannet% grep do_dend *.c ... plot.c:SEXP do_dend(SEXP call, SEXP op, SEXP args, SEXP env) plot.c:SEXP do_dendwindow(SEXP call, SEXP op, SEXP args, SEXP env) (This might be better continued on R-devel, if it need continuing.) -- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595
>>>>> "Rafael" == Rafael A Irizarry <ririzarr at jhsph.edu> >>>>> on Fri, 2 Jul 2004 15:50:46 -0400 (EDT) writes:Rafael> im using plclust and want the labels to be different Rafael> colors. i took a look at Rafael> getS3method("plot","hclust") and saw a call to Rafael> .Internal. i looked at the help on .Internal and Rafael> dont know where to go next. any help appreciated! {Brian already helped about finding where the C code for those .Internals is}. Just a few days ago, there was a question with almost identical content (though different wording). Please see in the archives for my answer with Subject 'Re: [R] Customizing Cluster Analysis plots created with hclust' Short answer: It will be possible in "R-devel" via as.dendrogram(..) Martin Maechler