I am working on cosine similarity and I am struggling with below two problems:
1- When two text are exact match, I am getting score as 5.000000000000023
.
2- When only one character is changed, I am getting score as 4.999999999999999
.
When I save the result in excel. For both the case,values are coming as 5.
I tried math.isclose
function to handle the above situation for my further analysis. But I want to save the exact score as it is irrespective of the Decimal places in Excel file as I want to use this output file in Qliksense for visualization and there if I keep the Threshold value for my score as 5.0
I may loose few records with value 5.000000000000023
.