The entire style of the visualization of the sketch is really impressive with the musical notation and the idea of transforming a drum machine into a melody one is really interesting. In the sketch, each music notes is represented by a note, which is clear and easy to understand. Adding the “clear” button also makes the user feel convenient to rewrite the melody and the slider to change the bpm also gives user more space to compose their melody.
For the development of the interaction, I think maybe adding the possibilities to change the length of the notes can make it more like a musical notation, but I am not sure about the difficulty of the coding here.
For the coding part, I notice the function toggleClear() to clear what users have drawn on the sketch, which is very useful for me since I am also considering adding this interaction in my project but I haven’t figured out by myself. I just realized that the logic of using the one in eliminating notes when clicking on it can also be applied here by learning his code.