"Scaramouch, Scaramouch, will you do the fandango?"
The Scaramouche in this case refers to a popular character in Italian Renaissance theatre, known for his buffoonish and comedic character. The fandango refers to a lively and energetic Spanish dance. So, the line invites the character Scaramouch to join in and perform the lively dance.