Displaying 4 results from an estimated 4 matches for "kuruvilla".
2007 Sep 26
5
sprucing up the R homepage
...ause people so often
"judge a book by its cover" (subconsciously or consciously), I'm
wondering if anyone thinks this is worthy of replacing the current
version? I want R to maximize R's appeal and albeit a small
improvement, hopefully this change will help a bit!
Regards,
Finny Kuruvilla
--
Finny Kuruvilla, MD, PhD
Department of Molecular Biology, Massachusetts General Hospital
Broad Institute of Harvard and MIT
Homepage: http://www.anchorcross.org/people/kuruvilla/
2007 Apr 26
3
A coding question involving variable assignments in ifelse()
Dear List,
Below is a simple, standard loss model that takes into account the
terms of an insurance policy:
deductible <- 15
coverage.limit <- 75
insurance.threshold <- deductible + coverage.limit
tmpf <- function() {
loss <- rlnorm(rpois(1, 3), 2, 5)
sum(ifelse(loss > insurance.threshold, loss - coverage.limit,
pmin(loss, deductible)))
}
net <- replicate(1000000, tmpf())
2007 Apr 27
4
Randomising matrices
I would like to be able to randomise presence-absence (i.e. binary)
matrices whilst keeping both the row and column totals constant. Is
there a function in R that would allow me to do this?
I'm working with vegetation presence-absence matrices based on field
observations. The matrices are formatted to have sites as rows and
species as columns. The presence of a species on a site is
2007 Apr 27
4
how to evaluate a dynamic variable?
Please help me evaluate a "dynamic variable" as show in the code
snippet below.
# regular variable
a = c(1,2,3,4)
# dynamic variable set at runtime
DV = "a"
eval(DV)
--> a
eval(eval(DV))
--> a
# what I want
something_goes_here(DV)
--> 1,2,3,4
Can someone teach me how to do this? Thanks very much.
- Bobby