statistical test for one quantitative and one categorical variable I am new to statistics and am trying on random data sets,
one analysis what I am doing is trying to find if there is a relationship between two variables, duration and success where duration is numeric continuous variable and the other, success is categorical.
The distribution of duration variable is not normal, so I believe I am doing non parametric testing, what do you think?

*

*Size of the dataset: 45957 for both variables

Given the distribution of "duration" column, I have this fig:

Now I want to analyze what is the best duration/length of time to have a successful campaign, I visualize duration with all types of status:

With the above relationship, there is no apparent conclusion, so I assume that success, is successful and rest all other categories are fail, I have this viz

Now, I want to be sure, I want to perform a test to come to a certain conclusion.
I have never performed a statistical test in real life so I don't know what to do and how to proceed in practice.
 A: Suppose the Failure group has observed duration values  x1
and the Success group has values x2, as randomly sampled in R
below:
set.seed(624)
x1 = rgamma(100, 4, .09)
x2 = rgamma(100, 4, .12)
x = c(x1, x2);  g=rep(1:2, each=100)
boxplot(x ~ g, col="skyblue2", pch=19, horizontal=T)


Then a two-sample Wilcoxon rank sum tests rejects the null hypothesis
that there is no difference in the locations of duration scores for
the two groups, with P-value 0.0023.
wilcox.test(x~g)

        Wilcoxon rank sum test 
        with continuity correction

data:  x by g
W = 6247, p-value = 0.002322
alternative hypothesis: 
   true location shift is not equal to 0

Note: You don't say what your sample sizes are. With $n_1, n_2$ as large
as 100, group sample means might be nearly normal. In that case,
a Welch two-sample t test would be appropriate, But I wouldn't
want to do a t test for such skewed data if sample sizes are moderate,
say 20 to 40.
The P-value for the Welch test is also about 0.002, but there is
no reason to expect two-sample Wilcoxon and t tests will generally have P-values that agree so closely. So you should decide in
advance which test to use. (Not 'fair' to try several tests and
then pick the one with the smallest P-value.)
t.test(x~g)$p.val
[1] 0.002118171

