Chi-square test for two vectors with very identical values I have two vectors with two levels:
vector 1:[1] 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 Levels: 0 1
vector 2:[1] 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 1 Levels: 0 1
As you can see these two vectors are very similar, the only difference is that level 0 exist in vector 2 (once) but not in vector 1. I tried to use the chi-square test to compare the distribution using R, however, I got an error message saying that:Error in stats::chisq.test(x, y) :  'x' and 'y' must have at least 2 levels
I tried to use fisher exact test but it gave me a p value = 1, which I don't believe is reasonable. Is there something wrong when I implement these tests? Or should switch to a more appropriate test for this task? Thanks for any suggestions!

The null hypotheses for the Fisher test is Group1 = Group2. The alternative test is Group1 $\neq$ Group2
A high p value means you "fail to reject" the Null hypothesis.
Therefore accepting the Null hypothesis (taking all of the assumptions and warnings into account) Group1 matches Group2
