ratio_to_pitch ratio (number)
Convert a frequency ratio to a midi note which when added to a note will transpose the note to match the frequency ratio.
Introduced in v2.7
ratio_to_pitch 2
#=> 12.0
ratio_to_pitch 0.5
#=> -12.0