Questions tagged [sampling]

Creating samples from a well-specified population using a probabilistic method and/or producing random numbers from a specified distribution. As this tag is ambiguous, please consider [survey-sampling] for the former and [monte-carlo] or [simulation] for the latter. For questions regarding creating random samples from known distributions, please consider using the [random-generation] tag.

Filter by
Sorted by
Tagged with
1
vote
0answers
56 views

Sampling without replacement - Normal sampling distribution [duplicate]

Most of the introductory stats textbooks, treat the sampling distribution of the mean as a normal distribution when sampling is done without replacement and n/N > 0.1. They just use of the finite ...
0
votes
1answer
221 views

Number of bootstrap replicates versus number of simulations

I have some confusion over bootstrap simulation in R. Here is the question: I am asked to use the following parameters to produce simulation: 500 bootstrap replicates 1000 simulations Sample size of ...
1
vote
0answers
138 views

How to deal with balanced training data and severely imbalanced testing data

My dataset is severely imbalanced, negative class is the majority and its records is almost 10000 larger than the positive class records. I'm using Python. Here's what I have already done: I used ...
2
votes
1answer
36 views

Sampling from specific distribution

Suppose I have two random variables $X$ and $Y$ that are independent. Also suppose that I can sample from $X+Y$ and $Y$. Is it possible to combine those two sampling algorithms to get samples for $X$.
2
votes
2answers
282 views

How to estimate high end percentile (e.g. >90%)

Say my dataset is of size $N$, and I want to calculate the 90th percentile. Suppose $N$ is too large that I can't compute the percentile by going through the entire dataset, what is the best way to ...
0
votes
0answers
36 views

Training a probability density from realization data

I want to learn a function that estimates a probability density over some 3D volume. I have a neural network that would work for this task and I would readily be able to train it, if I had density ...
1
vote
0answers
43 views

Estimator for repeated sampling and fitting

Say I have a Normal distribution $\mathcal{N_1}(\mu_1,\sigma_1)$. Now I will sample $N$ samples $X_1$ from this distribution, and use estimators for $\hat\mu_2$ and $\hat\sigma_2$ to fit a new ...
0
votes
1answer
271 views

expected value of sample median?

I am confused regarding a question I'm currently working on. how do I go about finding the expected value of a sample median? given that I have 10 balls of which 7 are no. 1's, 2 are no.2's and 1 ...
2
votes
2answers
152 views

Question on central limit theorem

I have a question regarding central limit theorem! I understand that as the sample size increases and gets large enough, the sampling distribution of the sample mean can said to be approximated by a ...
2
votes
1answer
47 views

Which cumulative distribution of F(X) is equal to the cumulative distribution of its sample median (as sample statistics)

We consider random sampling from a population in which the variable of interest $X$ has some cumulative distribution $F$. Next, we consider a simple random sample of size $n, X_1,\ldots,X_n,$ which ...
1
vote
0answers
184 views

Simulating Random Strings using Binomial/Multinomial Distributions

I am simulating some DNA sequences (containing characters A, C, G, and T) in R through specifying i) the number of sequences to generate (num.seqs) ii) the length of the generated sequences (length....
0
votes
0answers
14 views

How tailed area decided for hypothesis testing?

I have a doubt in basic hypothesis testing. Suppose I have a testing setup as below. I have assumed null hypothesis that my sampling distribution has $\mu = 60$, and I get a sample set with sample ...
0
votes
1answer
56 views

what type of sample is this?

I have the folowing table: according to this example, there are 40 observations distributed over 10 stores and 4 weeks of the month. Objective: to make a sample of 90%, 80%, 75% and 50% of the 40 ...
1
vote
0answers
15 views

How do I work out how many people would be selected in a specific age range by chance?

I have sampled individuals from 100 centres, all aged 5 to 7 years (a total of 1950 individuals). There were two groups that were sampled separately, at a higher rate: those aged 5 years and 11 ...
2
votes
1answer
65 views

What formula for a Confidence Interval of the difference in proportions when sample sizes are small

Suppose that we are interested in comparing two approximately normal sampling distributions described by random variables $ \displaystyle \frac{Y_1}{n_1} = N(p_1,p_1q_1) $ and $ \displaystyle \frac{...
1
vote
0answers
27 views

Expectation value of product of kronecker deltas

Consider the sum squared deviation $\text{SS}$ of $N$ samples $\hat{x}_1,\ldots,\hat{x}_N$ of a poisson random variable with mean $\mu$, i.e. $$ \text{SS} = \sum_{m=0}^{\infty} \left( \sum_{n=1}^N \...
1
vote
2answers
172 views

How to get any quantiles given median value and margin of error?

I am trying to get the values of the 25th and 75th quantile of the population based on two values that summarizes the samples: median value 90 percent margin of error I don't have any other ...
1
vote
0answers
111 views

Computational complexity of sampling from discrete and continuous distributions?

What is the computational complexity of sampling from any of these cases? I mean the computational complexity of the most efficient existing algorithm, not a possible algorithm or a lower bound. ...
2
votes
0answers
38 views

Transformation of probability distribution

I have a question about a snippet on page 526 in the PRML book of Bishop. Can someone explain to me why the right-hand side of equation (11.6) equals $z$? It's unclear to me where this derivation ...
2
votes
0answers
92 views

Statistical significance of percentage difference for a poll question with multiple options?

The question is: how to calculate the statistical significance of difference between percentages in the case described below? Suppose we have a poll question with $n$ answer options $A_1, …, A_n$, ...
1
vote
0answers
37 views

Z is a non-linear transform of X. I know the distribution of Z. Is it possible to sample from X?

I've got this problem where basically: $$ Z = f(X) \sim Normal(0, 1) $$ $f$ is pretty non-linear and I don't have its inverse function. In practice (using Stan's MCMC samplers or Tensorflow's ...
1
vote
0answers
709 views

Two-sample bootstrap hypothesis test

I am a beginner so please be indulgent. I would like to use a two-sample bootstrap hypothesis test for difference of means to this scenario: the impact of a new tool on team members daily output (...
4
votes
1answer
38 views

Find joint maximum of a sampled density

I used a sampling method to fit a model with three parameters to data, by supplying the likelihood function and priors. (I'm using JAGS but I think this applies to any method). I obtain triplets of ...
0
votes
0answers
19 views

Evaluating accuracy of the classifier based on sample?

I have a rather odd question which unfortunately goes beyond my knowledge of stats so any advice will be much appreciated. We built a clustering model on the text data (LDA) and then assigned classes ...
3
votes
0answers
150 views

Metropolis sampling for Bayesian networks

Gibbs sampling is a profound and popular technique for creating samples of Bayesian networks (BNs). Metropolis sampling is another popular technique, though - in my opinion - a less accessible method. ...
1
vote
0answers
22 views

Comparing averages of unequal population sizes

Imagine the following problem: I have 1000 plots of land. On each plot of land I plant 1000 Oak trees and 1 Elm tree. Each plot of land differs in multiple parameters (e.g. sunlight, soil type, ...
0
votes
1answer
160 views

Why do we use rejection sampling even we know the distribution?

I already read this post and I have the exact same questions. Below I pulled the first question and the answer from the post. Therefore we still use the distribution of p for the randomly ...
2
votes
0answers
17 views

Sample size for comparing two properties of time series data

I have a dataset of observations of two properties of an object (x and y), which are distributed over time, ...
1
vote
0answers
24 views

Sufficient statistics and wrong model assumption

Given any model for the underlying probability distribution $f(\theta)$, sufficient statistics provides us a way to estimate the model parameter $\theta$ with confidence without wasting the sample ...
1
vote
0answers
38 views

Sampling - optimal allocation for quantiles?

Say we have variable with a typical heavy tailed distribution following the Pareto principle. We divide the population into two strata (following the 80 / 20 rule) and use a stratified sampling design ...
3
votes
1answer
414 views

Acceptance-Rejection Method Acceptance Probability Proof

I did not fully understand the proof of the acceptance probability. The acceptance-rejection algorithm is described as follows: suppose you have RVs $X$ and $Y$ with densities $f$ and $g$, ...
0
votes
0answers
44 views

Distribution of posterior probabilities of samples from MCMC seems to be made up of several chi square components

I am running an MCMC sampler with a model that uses Cash's C statistic for the likelihood (along with gaussian priors), which is supposed to resemble a chi square distribution in the limit of large ...
3
votes
1answer
138 views

Feature Distribution in Cross-Validation

In the case of binary classification, stratified cross-validation only ensures that each fold contains roughly the same proportions of the two types of class labels. When does it make sense to also ...
1
vote
1answer
673 views

Using bootstrap to estimate the 95th percentile and confidence interval for skewed data

The problem: I have data of sales per day during a certain period (n=7939). The data is rather skewed (see the first image below). I would like to propose the number of items to resupply every day ...
-1
votes
2answers
29 views

Can I combine these samples from the same poplulation?

I have gathered some data from university students. First time, I went in two classes and explained everything to students and asked them to participate. the two classes had the same incentives, but ...
0
votes
1answer
50 views

How should I sample data from my dataset to be manually labeled for a SVM?

Assume I have a $2$-dimensional dataset $X=(x_1, x_2)$ where both features are not uniformly distributed over their respective ranges. I now need to select $100$ datapoints from this dataset to be ...
1
vote
0answers
49 views

Probability that 3 out of 4 sets have non-empty intersection

I have $4$ randomly sampled subsets from population set $S = \{1,2,...,100\}$. Each subset has size $24$. What is the probability that at least one element is common among $3$ out of $4$ subsets?
2
votes
0answers
24 views

Method to determine the required sample size: distance or number?

I'm working on a problem that requires me to carry out a survey of the condition of 5000 footpaths which cover total distance of 2573 km. The condition outcomes are either 'Pass' or 'Fail'. I only ...
0
votes
1answer
94 views

Probability of data of being generated by multiple models

Given one or more observations and multiple models, can I compute the probability of some observed data of being generated by each model? More specifically, I estimated $N$ dynamic models, each one ...
2
votes
1answer
92 views

How do you check that a sampler and a density correspond to the same random variate?

General Question If someone handed you a direct sampling algorithm and a density function, and they told you that the two corresponded to the same random variate, how would you check this? ...
1
vote
0answers
190 views

Negative sampling strategies for link prediction task

I've read the paper Variational Graph Auto-Encoders which aims to use auto-encoders for a link prediction task, such as predicting links in a citation network of publications. The loss is based on ...
4
votes
1answer
113 views

Should we balance the data set if the data is intrinsically unbalanced?

Say I want to predict the cancer rate(regression)/predict the whether a person has cancer or not(classification). The data intrinsically has few cancer patients/low cancer rate, say 1/200. And the ...
0
votes
1answer
478 views

What is the difference between monte carlo integration and gibbs sampling?

I am aware that both are methods of sampling from the posterior. MC integration replaces the integral by a sample MC sample. Is this sample independent? Gibbs sampling is a class of MCMC ...
3
votes
0answers
117 views

Constructing an unbiased estimator

Suppose we have a finite population $I_N$ of size $N$ on which we define a variable $\mathcal{Y}$. We also have a generic sampling design $(\mathcal{S},p)$ with first and second order inclusion ...
2
votes
2answers
58 views

How to sample a population

Suppose I have a set $\mathcal D$ of $n$ data points and want to generate a subset $\mathcal D_s$ with (potentially approximately) $m$ data points. What is the best way to do this in terms of ...
1
vote
0answers
86 views

Conditional sampling from a multivariate Gaussian Mixture

I am using scikit-learn to fit a gaussian mixture on a non-parametric multivariate distribution with three variables $ \mathbf{X} = (X_1, X_2, X_3) $ I want to sample from that distribution given ...
1
vote
2answers
98 views

When is bootstrapping helpful and used?

When is bootstrapping helpful and when should it be used? I have watched several videos so I understand what bootstrapping does (samples with replacement from a single sample many times and create a ...
2
votes
0answers
23 views

Reliability engineering design values from tests AS/NZS1170

To get design values (the strength of something, for example) designing to Australian/ New Zealand loading code you do $n$ tests and estimate the coefficient of variation of your parent population, $...
0
votes
1answer
552 views

Candidate Sampling for Softmax - Tensorflow; Sampling Probability

I am trying to understand the mathematics behind the sampled softmax in Tensorflow. They have the following document, trying to explain how the sampling process works: https://www.tensorflow.org/...
1
vote
1answer
57 views

How do I sample arbitrary probability mass functions? (Archimedean Copula)

I'm trying to use an algorithm (Marshall, Olkin) for exchangable archimedean Copula to generate realizations of multivariate probability distributions. One step includes sampling V which is F ...