Re: [Bioc-devel] Use set.seed inside function

2021-11-29 Thread Meng, Chen
ld *never* be done, because it will wreak havoc on a analyses and studies that rely on random numbers. My rule of thumb: only the end-user should be allowed to use set.seed(), which should typically be done at the top of their R scripts. /Henrik On Mon, Nov 29, 2021 at 1:23 PM Meng Chen wrote: Th

Re: [Bioc-devel] Use set.seed inside function

2021-11-29 Thread Meng Chen
ears that you don't actually want random colors, but instead you > want the same colors each time. Why not just generate the vector of 'random > distinct colors' one time and save the vector of colors? > > -Original Message- > From: Bioc-devel On Behalf Of Meng

[Bioc-devel] Use set.seed inside function

2021-11-29 Thread Meng Chen
Dear BioC team and developers, I am using BiocCheck to check my package, it returns a warning: " Remove set.seed usage in R code" I am using "set.seed" inside my functions, before calling function distinctColorPalette (randomcoloR package) in order to generate reproducible "random distinct colors