Compare two normal distribution that are unrelated I have two normal distributions, about the incomes of 2 stores (assuming they are unrelated).
For each of the 2 stores I have mean and standard deviation over a 40 days income samples.
Now, I'd like to compute the probability of Store A to perform better than Store B on a new day.
I was thinking to use
$$ (A-B) \sim \mathscr{N} (\mu_A - \mu_B, \sigma_A^2 + \sigma_A^2) , $$
And then do something like probability of B performing better than A is as $P(B>A) = P(A-B<0)$, and we use the normal distribution, to evaluate $A-B < 0$.
But I want to evaluate if my reasoning is correct.
Thanks!
 A: The main issue with your approach is that the comparison of incomes of the two stores needs to be done for the same day--in other words, there is a time component that needs to be taken into account in both the analysis and the sampling.
To illustrate, suppose your data on store A was collected during the holiday season when sales volume is generally high, but the data on store B was collected during a time when there was inclement weather.  Then comparing the mean income is not really fair, because the circumstances that have a causal relationship to income are different.  Therefore, the easiest way to control for this source of variability is to sample the store incomes on the same days over the same time period.  We call this "paired" sampling.
This is a very natural and intuitive approach and may seem obvious, but what this also means is that the analysis of this paired data must also account for this structure, and the way it does so depends on the question you are hoping to answer through that data.  For instance, if you are interested in testing whether the average daily incomes of the two stores are different, then you would perform a paired $t$-test.  But if you are interested in testing whether one store is more likely to have a larger daily income than the other store, then you do not care about the magnitude of the difference, only whether store A "wins" more frequently than store B, or vice versa--where a "win" means they earned more money, even if only by a little.  In such a case, you would perform a test on the proportion of wins in your sample.
Then there is the matter of prediction and estimation versus testing.  If you are interested in estimating the true mean incomes of each store, then a straightforward approach is to construct confidence intervals for those incomes--here, pairing is not needed.  More sophisticated would be a Bayesian approach to modeling the posterior predictive distribution of the next day's income based on the historical data.  Again, pairing is not used.  But if we are interested in predicting or estimating the difference in incomes, whether that is through a confidence interval estimate or a Bayesian model, then you must perform that analysis on the paired differences of the data.
If we take your question literally:

Compute the probability of Store A to perform better than Store B on a new day

then it seems to me that the approach to take, assuming the data is paired, is the test of proportions I mentioned.  Specifically, suppose our data structure is
$$A = (x_1, x_2, \ldots, x_n) \\ B = (y_1, y_2, \ldots, y_n)$$ where $x_i$ and $y_i$ are the incomes reported for Store A and Store B on sample day $i$, respectively.  Then we construct the statistic
$$S = \sum_{i=1}^n \mathbb 1(x_i > y_i)$$ which counts the number of days for which Store A earns more income than Store B.  Next, let $$N = \sum_{i=1}^n \mathbb 1(x_i \ne y_i),$$ that is to say, $N$ counts the number of days in which the incomes are not tied--if you do not observe any ties, then $N = n$.  Then $$S \mid N \sim \operatorname{Binomial}(N, p)$$ where $p$ is the probability that Store A "wins" against Store B.  (The unconditional statistic $S$ is not binomial because $N$ is random, but in practice, if ties are highly unlikely, we can ignore the conditionality.)  A hypothesis test of the form
$$H_0 : p = p_0 = 0.5 \quad \text{vs.} \quad H_1 : p \ne 0.5$$ with the test statistic $$Z = \frac{S/N - p_0}{\sqrt{p_0(1-p_0)/N}} \sim \operatorname{Normal}(0,1)$$ is asymptotically standard normal for sufficiently large $N$.
But if your goal is to estimate the probability $p$, then you could construct the confidence interval
$$\hat p \pm z_{\alpha/2}^* \sqrt{\hat p (1 - \hat p)/N},$$ where $\hat p = S/N$ is the observed win rate for Store A, and $z_{\alpha/2}^*$ is the critical value for a $100(1-\alpha)\%$ confidence interval and equals the upper $\alpha/2$ quantile of the standard normal distribution.
Alternatively the Bayesian model would employ a binomial likelihood with beta prior, whose posterior for the probability of Store A winning on the next day is beta distributed.  But this answer is already too long for a detailed treatment.
A: Not really, it seems like you are mixing two different concepts. You would be evaluating that the mean of B is greater than the mean of A, e.g. that overall B receives higher income, not the probability that B performs better than A on any given day. In addition, you wouldn't be finding the probability that B has a greater mean than A; it's more like testing if B has a greater mean than A at all.
A: Several comments:
I agree with @heropup (+1) that you need data for differences $D$ of Store B sales minus Store A sales on the same days. But then you don't have independent data unless the 40 days
are quite far apart. (A time-series approach might look for weekly, monthly, or
seasonal effects.
If you you have independent normal differences d then you could use $\bar d$ and $S_d$ to estimate $\mu_d, \sigma_d.$ It's not quite clear what you mean by the probability
that $B > A$ or $D > 0.$ Are you asking for daily predictions or are you willing
to deal with historical trends and just hope they 'predict' the future. You might want
to look at distinctions between confidence intervals (for the difference on a typical randomly past day) or prediction intervals for a new difference (with it's own
hypothetical variability, in view of what is known from the past).
If you just want $P(D > 0),$ for a randomly chosen day, then that's easy to compute for normal $D$ with with
$\hat\mu_d = 0.2, \sigma_d = 2.12,$ from a random normal sample. (In R.)
1 - pnorm(0, 0.2, 2.12)
[1] 0.5375803

