blazingbunny commited on
Commit
6ef28f0
1 Parent(s): 98a4de8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -2
app.py CHANGED
@@ -39,12 +39,17 @@ for idx, sitemap_url in enumerate(sitemap_urls):
39
  # Word frequency for single words, excluding common words
40
  word_freq = word_frequency(slugs_filtered, phrase_len=1)
41
  st.subheader(f"Most-frequently used words in article titles for {sitemap_url} (excluding common words)")
42
- st.dataframe(word_freq.head(10))
43
 
44
  # Word frequency for two-word phrases, excluding common words
45
  word_freq_phrases = word_frequency(slugs_filtered, phrase_len=2)
46
  st.subheader(f"Most-frequently used two-word phrases in article titles for {sitemap_url} (excluding common words)")
47
- st.dataframe(word_freq_phrases.head(10))
 
 
 
 
 
48
 
49
  # Plotting trends
50
  for trend_name, resample_rule, ylabel in [("Yearly", "A", "Count"), ("Monthly", "M", "Count"), ("Weekly", "W", "Count")]:
 
39
  # Word frequency for single words, excluding common words
40
  word_freq = word_frequency(slugs_filtered, phrase_len=1)
41
  st.subheader(f"Most-frequently used words in article titles for {sitemap_url} (excluding common words)")
42
+ st.dataframe(word_freq.head(100))
43
 
44
  # Word frequency for two-word phrases, excluding common words
45
  word_freq_phrases = word_frequency(slugs_filtered, phrase_len=2)
46
  st.subheader(f"Most-frequently used two-word phrases in article titles for {sitemap_url} (excluding common words)")
47
+ st.dataframe(word_freq_phrases.head(100))
48
+
49
+ # Word frequency for three-word phrases, excluding common words
50
+ word_freq_trigrams = word_frequency(slugs_filtered, phrase_len=3)
51
+ st.subheader(f"Most-frequently used three-word phrases in article titles for {sitemap_url} (excluding common words)")
52
+ st.dataframe(word_freq_trigrams.head(100))
53
 
54
  # Plotting trends
55
  for trend_name, resample_rule, ylabel in [("Yearly", "A", "Count"), ("Monthly", "M", "Count"), ("Weekly", "W", "Count")]: