# Compute/approximate percentile from percentiles of smaller time windows

As the title says, I am interested in computing or approximating a percentile (e.g. 95%) for a large time interval (e.g., 1h) based on the percentiles of smaller time windows (30s). I am aware that the correct way would be to compute the percentile from scratch starting from the raw data. However, the data set is very large and would take way too much time (a 30s window can have 100k-100M data points).

To simplify things, assume that the distribution for all the time intervals are the same but the constants might be somewhat different. For example, values in a window follow a Poisson distribution but the parameters of the distribution might vary somewhat between windows. To put it in more visual terms, the shape of all the distributions is the same but there might be a "scaling" factor that changes.

I do not require a mathematical proof but some insight on what would be a reasonable way to proceed. Right now I am computing the median value of all the percentiles I am interested in. Could I improve on this?

If the rate is nearly the same, say $\lambda$ for a 30 second time interval, then the rate for a one hour time interval would be $120\lambda.$ So you would need to find the 95th percentile of $\mathsf{Pois}(100\lambda).$ If $\lambda$ itself is random (perhaps according to a gamma distribution), that might introduce another significant component of variability.
It might help toward a realistic model if you could give numbers of observed events in several typical 30-second intervals. Without any idea at all of the size or variability of the $\lambda$s, useful speculation even about approximate models is not possible. You say you have thousands or millions of 'records' every 30 seconds, but how many Poisson events do you typically have in a 30-second time period?