distributional icon indicating copy to clipboard operation
distributional copied to clipboard

Vectorised distributions for R

Results 24 distributional issues
Sort by recently updated
recently updated
newest added

Given a *cdf* F defined on positive numbers for a random variable X, we can find the reciprocal random variable Y = 1/X and its *cdf* G as follows: `G(y)...

I'm not sure the exact problem, but it seems that the `mean()` of transformed distributions is not always correct. Here's an example of `exp()` applied to `dist_normal()`, which should yield...

enhancement

Currently we cannot add two distributions together: ``` r library(distributional) d Error in dist$inverse(at): Inverting transformations for distributions is not yet supported. ``` Created on 2024-04-12 with [reprex v2.1.0](https://reprex.tidyverse.org) But...

## Summary As discussed in #97, this PR implements automatic symbolic differentiation of the inverse transformation function. It also allows users to supply a `deriv` function to `dist_transformed()`, in addition...

The vectorisation of p/d/q/r distribution functions can introduce some surprising vectorisation behaviour. distributional has different (and extended) behaviour to this, which would need some learning for more advanced users. Ref:...

While doing some testing I noticed that density, cdf and quantile sometimes return vectors, sometimes lists: ```r library(distributional) density(dist_normal(), c(0,1)) # returns list #> [[1]] #> [1] 0.3989423 0.2419707 density(c(dist_normal(),dist_normal()),...

Relevant information: https://github.com/mitchelloharawild/distributional/issues/100#issuecomment-2039449602

While we figure out what the best approach for #101 is, I thought it might be good to extract some of the tests I wrote for it in a separate...