| Title: | Data and 'Shiny' Application for the Tv Show 'SouthPark' |
| Version: | 1.1.1 |
| Description: | Ratings, votes, swear words and sentiments are analysed for the show 'SouthPark' through a 'Shiny' application after web scraping from 'IMDB' and the website https://southpark.fandom.com/wiki/South_Park_Archives. |
| License: | MIT + file LICENSE |
| URL: | https://github.com/Amalan-ConStat/SouthParkRshiny,https://amalan-con-stat.shinyapps.io/SouthParkRshiny/ |
| BugReports: | https://github.com/Amalan-ConStat/SouthParkRshiny/issues |
| Depends: | R (≥ 4.1.0) |
| Imports: | box, bslib (≥ 0.9.0), config (≥ 0.3.2), ggplot2, ggpubr, golem (≥ 0.4.1), kableExtra, knitr, shiny (≥ 1.8.0), shinydashboard, patchwork, ggimage, ggraph, ggtext |
| Suggests: | gridlayout |
| Additional_repositories: | https://amalan-constat.github.io/drat/ |
| Encoding: | UTF-8 |
| LazyData: | true |
| LazyDataCompression: | xz |
| Config/roxygen2/version: | 8.1.0 |
| NeedsCompilation: | no |
| Packaged: | 2026-10-06 13:04:24 UTC; amala |
| Author: | Amalan Mahendran [aut, cre] |
| Maintainer: | Amalan Mahendran <amalan0595@gmail.com> |
| Repository: | CRAN |
| Date/Publication: | 2026-10-06 22:00:20 UTC |
Basic Plots
Description
Average rating and votes summarised in different ways.
Usage
Basic_Plots
Format
A list with
1Number of Votes vs Average Rating
2Number of episodes in seasons and their runtime
3Average ratings and votes for each season
Examples
length(Basic_Plots)
Cooccurrence Plots
Description
A network showing how frequently Cartman, Stan, Kyle and Kenny speak in the same episodes across the selected seasons. Nodes represent characters, displayed using their images. Connections are undirected, with widths and labels showing Jaccard similarity: the number of episodes containing both characters divided by the number containing either character. Higher values indicate greater co-occurrence. Shared episodes do not necessarily indicate direct interaction.
Usage
Cooccurrence_Plots
Format
An object of class ggraph (inherits from ggplot2::ggplot, ggplot, ggplot2::gg, S7_object, gg) of length 1.
Examples
length(Cooccurrence_Plots)
Friends Sentiment Plots
Description
Three heatmaps summarising sentiment word rates for Cartman, Stan, Kyle and Kenny across seasons using the Bing, NRC and Loughran dictionaries. Columns represent seasons and rows represent characters. Green indicates a higher positive rate, red a higher negative rate, and white equal rates. Each tile displays the higher rate per 100 words spoken by that character in that season. Each dictionary has its own colour scale. Colour intensity represents the higher rate, rather than the difference between the two rates.
Usage
Friends_Sentiment_Plots
Format
An object of class patchwork (inherits from ggplot2::ggplot, ggplot, ggplot2::gg, S7_object, gg) of length 3.
Examples
length(Friends_Sentiment_Plots)
N Grams Plots
Description
Three and four word phrases common among seasons, main characters and supporting characters are summarised through a plot here, from the script data.
Usage
N_Grams_Plots
Format
A list with
1Three word pharases over seasons
2Four word pharases over seasons
3Three word pharases over main characters
4Four word pharases over main characters
5Three word pharases over supporting characters
6Four word pharases over supporting characters
Examples
length(N_Grams_Plots)
Ratings Votes Plots
Description
Detailed plots for ratings and votes from the IMDB data.
Usage
Ratings_Votes_Plots
Format
A list with
1Rating for all seasons and episodes
2Votes for all seasons and episodes
Examples
length(Ratings_Votes_Plots)
Sentiment General Plots
Description
A three-panel plot summarising sentiment matches using the Bing, NRC and Loughran dictionaries. Lines show positive and negative word matches per 100 words in each season, read against the right-hand axis. Bars show the number of episodes with more positive than negative matches, or more negative than positive matches, read against the left-hand axis. Episodes with equal positive and negative counts are omitted from the bars.
Usage
Sentiment_General_Plots
Format
An object of class ggplot2::ggplot (inherits from ggplot, ggplot2::gg, S7_object, gg) of length 1.
Examples
length(Sentiment_General_Plots)
SouthPark IMDB Data Data from the IMDB website are extracted for the show. The data consists of season, episode, primarytitle, originaltitle, year, runtime(in minutes), averagerating and number of votes.
Description
SouthPark IMDB Data Data from the IMDB website are extracted for the show. The data consists of season, episode, primarytitle, originaltitle, year, runtime(in minutes), averagerating and number of votes.
Usage
SouthPark_IMDB_Data
Format
A dataframe with
SeasonSeason Number
EpisodeEpisode Number
PrimaryTitleprimary title of the episode
OriginalTitleoriginal title of the episode
Yearyear the episode was aired
Runtimeruntime in minutes
AverageRatingaverage rating out of 10
NumberOfVotesnumber of votes recorded
Examples
sort(unique(SouthPark_IMDB_Data$Season)) # the seasons of the show
mean(SouthPark_IMDB_Data$AverageRating) # the average rating of the show
sum(SouthPark_IMDB_Data$NumberOfVotes) # sum of the number of votes
SouthPark Script Data
Description
Data for the scripts scraped from the website are stored here. The data consists of season, episode, character and line.
Usage
SouthPark_Script_Data
Format
A dataframe with
SeasonSeason Number
EpisodeEpisode Number
CharacterCharacter Name
LineThe lines the character spoke
Examples
unique(SouthPark_Script_Data$Season) # the seasons of the show
unique(SouthPark_Script_Data$Character) |> length() # the unique characters in the show
SouthPark Summary
Description
Overall summary plot from the script data.
Usage
Southpark_Summary
Format
A dataframe with
Triviatrivial information labels
Valuesdata for the trivial information
Support Sentiment Plots
Description
Three heatmaps summarising sentiment word rates for Liane, Randy, Sharon, Gerald, Sheila and Mr. Garrison across seasons using the Bing, NRC and Loughran dictionaries. Columns represent seasons and rows represent characters. Green indicates a higher positive rate, red a higher negative rate, and white equal rates. Each tile displays the higher rate per 100 words spoken by that character in that season. Grey indicates no tokenized dialogue. Each dictionary has its own colour scale. Colour intensity represents the higher rate, rather than the difference between the two rates.
Usage
Support_Sentiment_Plots
Format
An object of class patchwork (inherits from ggplot2::ggplot, ggplot, ggplot2::gg, S7_object, gg) of length 3.
Examples
length(Support_Sentiment_Plots)
Swear Words Plots
Description
Swear word plots for main and supporting characters per seasons. Total number of words and unique words are summarised through plots.
Usage
Swear_Words_Plots
Format
A list with
1Swear word rate per 100 words in general
2Swear word rate per 100 words for main characters
3Swear word rate per 100 words for supporting characters
Examples
length(Swear_Words_Plots)
Transition Plots
Description
A network showing speaking transitions between Cartman, Stan, Kyle and Kenny across the selected seasons. Nodes represent characters, displayed using their images. An arrow from A to B indicates that B speaks immediately after A within the same episode. Arrow widths and labels show the percentage of transitions from A to B, using all transitions from A to a different speaker as the denominator. Only connections between the four selected characters are displayed. Speaking order does not necessarily indicate whom a character addresses.
Usage
Transition_Plots
Format
An object of class ggraph (inherits from ggplot2::ggplot, ggplot, ggplot2::gg, S7_object, gg) of length 1.
Examples
length(Transition_Plots)
Run the Shiny Application
Description
Run the Shiny Application
Usage
run_app(...)
Arguments
... |
list of golem options. |
Value
used for side effects