Entering edit mode
Benjamin Otto
▴
830
@benjamin-otto-1519
Last seen 10.2 years ago
Dear bioconductors,
some time ago in one of the discussion about RMA-bimodality Wolfgang
Huber and Peter Warren pointed out, that a similar distribution could
be
simulated with
> n <- 10000
> z = 20 + exp(c(rnorm(n), 3+rnorm(n)))
> plot(density(log2(z)))
Now here comes a more mathematical question. Suppose the following
> x0 <- rnorm(n)
> x1 <- x0 + 3
It is quite easy to get the same density in two ways:
for x0 it's super easy:
> plot(density(x0))
> plot(x0,dnorm(x0))
and for x1 it's still intuitive:
> plot(density(x1))
> plot(x1,dnorm(x1 - 3))
That's because we are currently only shifting the distribution. But
how
do I transform the x-values for y-value calculation via dnorm() when
applying the more complex exponential function?
> x2 <- exp(x0)
> plot(density(x2))
> plot(x2, ..???..)
best regards
Benjamin
--
Pflichtangaben gem?? Gesetz ?ber elektronische Handelsregister und
Genossenschaftsregister sowie das Unternehmensregister (EHUG):
Universit?tsklinikum Hamburg-Eppendorf
K?rperschaft des ?ffentlichen Rechts
Gerichtsstand: Hamburg
Vorstandsmitglieder:
Prof. Dr. J?rg F. Debatin (Vorsitzender)
Dr. Alexander Kirstein
Ricarda Klein
Prof. Dr. Dr. Uwe Koch-Gromus