The number 0 is contained in a confidence interval obtained by using bootstrap. Is the value of the parameter significant? I have the following two ordinal variables:
x=c(29 ,19 ,31 ,48 ,11 ,33 ,23 ,16 ,19 ,9 ,24 ,5 ,22 ,10 ,26 ,18 ,16 ,26 ,10 ,25 ,16 ,17 ,18 ,21 ,19 ,11 ,11 ,9 ,73 ,37 ,25 ,11 ,16 ,19 ,15 ,16 ,26 ,21 ,17)

y=c(3 ,2 ,1 ,3 ,2 ,2 ,1 ,1 ,1 ,1 ,2 ,1 ,1 ,1 ,1 ,1 ,2 ,2 ,2 ,2 ,2 ,1 ,2 ,2 ,2 ,3 ,1 ,1 ,3 ,1 ,2 ,1 ,1 ,1 ,1 ,1 ,1 ,2 ,1)

When I calculate the correlation between the two previous vectors:
cor.test(x,y,method = "spearman")

The result is:
Cannot compute exact p-value with ties
    Spearman's rank correlation rho

data:  x and y
S = 6665, p-value = 0,04324
alternative hypothesis: true rho is not equal to 0
sample estimates:
      rho 
0,3254013

In the previous result p-value <0.05; however when I apply the bootstrap:
dat = data.frame(x,y)
set.seed(1)

statistic1 = function(data, i) {
    cor(data[i, "x"], data[i, "y"], method='spearman')
  }

b3 <- boot(dat,statistic1,R = 1000)
b3
boot.ci(b3, type = c("perc", "bca"))

The result is:
Intervals : 
Level     Percentile            BCa          
95%   (-0,0178,  0,6246 )   (-0,0547,  0,6109 ) 

The result applying bootstrap gives me a ci that contains the number 0. If the zero is included within the ci does it mean that the value of the correlation (0.325) is not significant?
Thanks in advance

In frequentist statistics, confidence intervals and p-values are directly related to one another. If your null hypothesis that the correlation is zero, and your 95% confidence interval includes zero, then you indeed fail to reject the null hypothesis with an alpha set at .05.
The cor.test is using a test statistic with a closed-form solution, while the bootstrap is using a computational method to get a confidence interval. I unfortunately don't know much about how cor.test is calculating the p-value for the Spearman rank correlation—so I can't tell you which method to trust more. My gut says go with the bootstrap, but I may very well be wrong.
It looks like you've unfortunately got something right on the line of "being significant," so while different methods generally agree, they may provide slightly different answers. And sometimes that means one can cross the significance threshold and others don't.
This is a good example of researcher degrees of freedom (one may be tempted to report the one that is significant), and it also demonstrates how the significance level we set at .05 is arbitrary.
