In the context of teaching-learning of motor skills in a virtual environment, videos are generally used. -e person who wants to learn a certain movement watches a video and tries to perform the activity. In this sense, feedback is rarely thought of. -is article proposes an algorithm in which two periodic movements are compared, the one carried out by an expert and the one carried out by the person who is learning, in order to determine how closely these two movements are performed and to provide feedback from them. -e algorithm starts from the capture of data through a wearable device that yields data from an accelerometer; in this case, the data of the expert and the data of the person who is learning are captured in a dataset of salsa dance steps. Adjustments are made to the data in terms of Pearson iterations, synchronization, filtering, and normalization, and DTW, linear regression, and error analysis are used to make the corresponding comparison of the two datasets. With the above, it is possible to determine if the cycles of the two signals coincide and how closely the learner's movements resemble those of the expert.