Abstract
The objective of this chapter is to conduct a sentiment analysis of the Harry Potter novel series written by British author J.K. Rowling. The text of the series is collected from GitHub as an R package provided by Bradley Boehmke. The chapter analyzed the text by R programming to explore dominant sentiments using a lexicon approach of natural language processing (NLP). The results revealed that Professor Slughorn scored the most positive sentiment among the main characters that have heroic qualities; Death Eaters had the most negative sentiment among the anti-hero characters; negative sentiment in the text around the anti-hero characters increased significantly, while the positive sentiment around the hero characters remained constant as the story progressed throughout the series; among the series of novels, The Deathly Hallows contained the most negative sentiment; among all the houses of Hogwarts School of Witchcraft and Wizardry, Hufflepuff had the most positive sentiment; and each book of the series appeared negative until the final chapter, which always ended with a positive sentiment.
Talk to us
Join us for a 30 min session where you can share your feedback and ask us any queries you have
Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.