The FINDHOM tool produces text output which we need to interpret using the concept of matches, queries and scores and statistics about matches. We’ll deal with extracting information from it’s output in later lessons but let’s start with some use of Python types.
Let’s start with this statement
best_match_identity = 0.8When you run this code in a notebook, do you expect to see output? Why or why not?
Imagine that you want to test to see if the identity of a new match (stored in
new_match) is as good as the best match (i.e.best_match_identity). Would you use the following code? Explain.
if new_match == best_match_identity:
print('The new match is equally good as the best match')If you wanted to see if your new match has better identify than the current match, could you use the following code? Explain why and why the answer might be different to the previous question
if new_match > best_match_identity:
print('The new match is better than the current best match')If you wanted to test that two floating point values were equal up to 3 decimal points in Python, how could you do that? Think about
if,floattypes and other ways of representing numbers.Sandflies of the sub-family
Phlebotominaeare vectors for diseases such as leishmaniasis. In the “Old World”, two genera of sandflies are typically found, Phlebotomus and Sergentomyia. If the sample genus name is in a variablesample_genus, how would you test to see if it is one of these two genera or perhaps another, unknown, genus?
The answers to these exercises will be discussed in the next lesson.