{"id":876,"date":"2019-05-11T20:13:46","date_gmt":"2019-05-11T20:13:46","guid":{"rendered":"http:\/\/ai.intelligentonlinetools.com\/ml\/?p=876"},"modified":"2019-05-20T00:38:21","modified_gmt":"2019-05-20T00:38:21","slug":"twitter-text-miningwith-python","status":"publish","type":"post","link":"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/","title":{"rendered":"Twitter Text Mining\twith Python"},"content":{"rendered":"<div class=\"aiteo69d781163abfb\" ><script async src=\"\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js\"><\/script>\n<!-- Text analytics techniques 728_90 horizontal top -->\n<ins class=\"adsbygoogle\"\n     style=\"display:inline-block;width:728px;height:90px\"\n     data-ad-client=\"ca-pub-3416618249440971\"\n     data-ad-slot=\"2926649501\"><\/ins>\n<script>\n(adsbygoogle = window.adsbygoogle || []).push({});\n<\/script><\/div><style type=\"text\/css\">\r\n.aiteo69d781163abfb {\r\nmargin: 5px; padding: 0px;\r\n}\r\n@media screen and (min-width: 1201px) {\r\n.aiteo69d781163abfb {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 993px) and (max-width: 1200px) {\r\n.aiteo69d781163abfb {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 769px) and (max-width: 992px) {\r\n.aiteo69d781163abfb {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 768px) and (max-width: 768px) {\r\n.aiteo69d781163abfb {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (max-width: 767px) {\r\n.aiteo69d781163abfb {\r\ndisplay: block;\r\n}\r\n}\r\n<\/style>\r\n\n<p><img decoding=\"async\" loading=\"lazy\" src=\"http:\/\/ai.intelligentonlinetools.com\/ml\/wp-content\/uploads\/2019\/05\/Twitter_API.jpg\" alt=\"\" width=\"640\" height=\"277\" class=\"aligncenter size-full wp-image-886\" srcset=\"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-content\/uploads\/2019\/05\/Twitter_API.jpg 640w, https:\/\/ai.intelligentonlinetools.com\/ml\/wp-content\/uploads\/2019\/05\/Twitter_API-300x130.jpg 300w\" sizes=\"(max-width: 640px) 100vw, 640px\" \/><\/p>\n<p>In this post (and few following posts) we will look how to get interesting information by extracting links from results of Twitter search by keywords and using machine learning text mining. While there many other posts on the same topic, we will cover also additional small steps that are needed to process data. This includes such tasks as unshorting urls, setting date interval, saving or reading information. <\/p>\n<p>Below we will focus on extracting links from results of Twitter search API python.<\/p>\n<h2>Getting Login Information for Twitter API<\/h2>\n<p>The first step is set up application on Twitter and get login information. This is already described in some posts on the web [1].<br \/>\nBelow is the code snippet for this:<\/p>\n<pre class=\"brush: python; title: ; notranslate\" title=\"\">your code here<\/pre>\n<pre class=\"brush: python; title: ; notranslate\" title=\"\">\r\nimport tweepy as tw\r\n    \r\nCONSUMER_KEY =&quot;xxxxx&quot;\r\nCONSUMER_SECRET =&quot;xxxxxxx&quot;\r\nOAUTH_TOKEN = &quot;xxxxx&quot;\r\nOAUTH_TOKEN_SECRET = &quot;xxxxxx&quot;\r\n\r\nauth = tw.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)\r\nauth.set_access_token(OAUTH_TOKEN, OAUTH_TOKEN_SECRET)\r\napi = tw.API(auth, wait_on_rate_limit=True)\r\n<\/pre>\n<h2>Defining the Search Values<\/h2>\n<p>Now you can do search by keywords or hashtags and get tweets.<br \/>\nWhen we do search we might want to specify the start day so it will give results dated on this start day or after.<\/p>\n<p>For this we can code as the following:<\/p>\n<pre class=\"brush: python; title: ; notranslate\" title=\"\">\r\nfrom datetime import datetime\r\nfrom datetime import timedelta\r\n\r\nNUMBER_of_TWEETS = 20\r\nSEARCH_BEHIND_DAYS=60\r\ntoday_date=datetime.today().strftime('%Y-%m-%d')\r\n\r\n\r\ntoday_date_datef = datetime.strptime(today_date, '%Y-%m-%d')\r\nstart_date = today_date_datef - timedelta(days=SEARCH_BEHIND_DAYS)\r\n\r\n\r\nfor search_term in search_terms:\r\n  tweets = tw.Cursor(api.search,\r\n                   q=search_term,\r\n                   lang=&quot;en&quot;,\r\n                   since=SEARCH_BEHIND_DAYS).items(NUMBER_of_TWEETS)\r\n<\/pre>\n<p>The above search will return 20 tweets and will look only within 60 days from day of search. If we want use fixed date we can replace with  <em>since=&#8217;2019-12-01&#8242;<\/em> <\/p>\n<h2>Processing Extracted Links<\/h2>\n<p>Once we got tweets text we can extract links. However we will get different types of links. Some are internal twitter links, some are shorten, some are regular urls.<\/p>\n<p>So here is the function to sort out the links. We do not need internal links &#8211; the links that belong to Twitter navigation or other functionality.<\/p>\n<pre class=\"brush: python; title: ; notranslate\" title=\"\">\r\ntry:\r\n    import urllib.request as urllib2\r\nexcept ImportError:\r\n    import urllib2\r\n\r\n\r\nimport http.client\r\nimport urllib.parse as urlparse   \r\n\r\ndef unshortenurl(url):\r\n    parsed = urlparse.urlparse(url) \r\n    h = http.client.HTTPConnection(parsed.netloc) \r\n    h.request('HEAD', parsed.path) \r\n    response = h.getresponse() \r\n    if response.status &gt;= 300 and response.status &lt; 400 and response.getheader('Location'):\r\n        return response.getheader('Location') \r\n    else: return url \r\n<\/pre>\n<p>Once we got links we can save urls information in csv file. Together with the link we save twitter text, date.<br \/>\nAdditionally we count number of hashtags and links and also save this information into csv files.  So the output of program is 3 csv files. <\/p>\n<h2>Conclusion<\/h2>\n<p>Looking in the output file we can quickly identify the links of interest.  For example just during the testing this script I found two interesting links that I was not aware.  In the following post we will look how to do even more automation for finding cool links using Twitter text mining.  <\/p>\n<p>Below you can find full source code and the references to web resources that were used for this post or related to this topic.<\/p>\n<pre class=\"brush: python; title: ; notranslate\" title=\"\">\r\n# -*- coding: utf-8 -*-\r\n\r\nimport tweepy as tw\r\nimport re\r\nimport csv\r\n\r\nfrom datetime import datetime\r\nfrom datetime import timedelta\r\n\r\nNUMBER_of_TWEETS = 20\r\nSEARCH_BEHIND_DAYS=60\r\ntoday_date=datetime.today().strftime('%Y-%m-%d')\r\n\r\n\r\ntoday_date_datef = datetime.strptime(today_date, '%Y-%m-%d')\r\nstart_date = today_date_datef - timedelta(days=SEARCH_BEHIND_DAYS)\r\ntry:\r\n    import urllib.request as urllib2\r\nexcept ImportError:\r\n    import urllib2\r\n\r\n\r\nimport http.client\r\nimport urllib.parse as urlparse   \r\n\r\ndef unshortenurl(url):\r\n    parsed = urlparse.urlparse(url) \r\n    h = http.client.HTTPConnection(parsed.netloc) \r\n    h.request('HEAD', parsed.path) \r\n    response = h.getresponse() \r\n    if response.status &gt;= 300 and response.status &lt; 400 and response.getheader('Location'):\r\n        return response.getheader('Location') \r\n    else: return url    \r\n    \r\n    \r\nCONSUMER_KEY =&quot;xxxxx&quot;\r\nCONSUMER_SECRET =&quot;xxxxxxx&quot;\r\nOAUTH_TOKEN = &quot;xxxxxxxx&quot;\r\nOAUTH_TOKEN_SECRET = &quot;xxxxxxx&quot;\r\n\r\n\r\nauth = tw.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)\r\nauth.set_access_token(OAUTH_TOKEN, OAUTH_TOKEN_SECRET)\r\napi = tw.API(auth, wait_on_rate_limit=True)\r\n# Create a custom search term \r\n\r\nsearch_terms=[&quot;#chatbot -filter:retweets&quot;, \r\n              &quot;#chatbot+machine_learning -filter:retweets&quot;, \r\n              &quot;#chatbot+python -filter:retweets&quot;,\r\n              &quot;text classification -filter:retweets&quot;,\r\n              &quot;text classification python -filter:retweets&quot;,\r\n              &quot;machine learning applications -filter:retweets&quot;,\r\n              &quot;sentiment analysis python  -filter:retweets&quot;,\r\n              &quot;sentiment analysis  -filter:retweets&quot;]\r\n              \r\n        \r\n              \r\ndef count_urls():\r\n       url_counted = dict() \r\n       url_count = dict()\r\n       with open('data.csv', 'r', encoding=&quot;utf8&quot; ) as csvfile: \r\n           line = csvfile.readline()\r\n           while line != '':  # The EOF char is an empty string\r\n            \r\n               line = csvfile.readline()\r\n               items=line.split(&quot;,&quot;)\r\n               if len(items) &lt; 3 :\r\n                          continue\r\n                           \r\n               url=items[1]\r\n               twt=items[2]\r\n               # key =  Tweet and Url\r\n               key=twt[:30] + &quot;___&quot; + url\r\n               \r\n               if key not in url_counted:\r\n                      url_counted[key]=1\r\n                      if url in url_count:\r\n                           url_count[url] += 1\r\n                      else:\r\n                           url_count[url] = 1\r\n       print_count_urls(url_count)             \r\n\r\n       \r\ndef print_count_urls(url_count_data):\r\n   \r\n         for key, value in url_count_data.items():\r\n              print (key, &quot;=&gt;&quot;, value)\r\n              \r\n         with open('data_url_count.csv', 'w', encoding=&quot;utf8&quot;, newline='' ) as csvfile_link_count: \r\n            fieldnames = ['URL', 'Count']\r\n            writer = csv.DictWriter(csvfile_link_count, fieldnames=fieldnames)\r\n            writer.writeheader() \r\n            \r\n            for key, value in url_count_data.items():\r\n                 writer.writerow({'URL': key, 'Count': value })   \r\n            \r\n           \r\ndef extract_hash_tags(s):\r\n    return set(part[1:] for part in s.split() if part.startswith('#'))\r\n    \r\n\r\n   \r\ndef save_tweet_info(tw, twt_dict, htags_dict ):\r\n   \r\n    if tw not in twt_dict:\r\n        htags=extract_hash_tags(tw)\r\n        twt_dict[tw]=1\r\n        for ht in htags:\r\n            if ht in htags_dict:\r\n                htags_dict[ht]=htags_dict[ht]+1\r\n            else:   \r\n                htags_dict[ht]=1\r\n\r\n\r\ndef print_count_hashtags(htags_count_data):\r\n        \r\n         for key, value in htags_count_data.items():\r\n              print (key, &quot;=&gt;&quot;, value)\r\n              \r\n         with open('data_htags_count.csv', 'w', encoding=&quot;utf8&quot;, newline='' ) as csvfile_link_count: \r\n            fieldnames = ['Hashtag', 'Count']\r\n            writer = csv.DictWriter(csvfile_link_count, fieldnames=fieldnames)\r\n            writer.writeheader() \r\n            \r\n            for key, value in htags_count_data.items():\r\n                 writer.writerow({'Hashtag': key, 'Count': value })          \r\n        \r\n\r\n\r\ntweet_dict = dict() \r\nhashtags_dict = dict()\r\n\r\n                 \r\nfor search_term in search_terms:\r\n  tweets = tw.Cursor(api.search,\r\n                   q=search_term,\r\n                   lang=&quot;en&quot;,\r\n                   #since='2019-12-01').items(40)\r\n                   since=SEARCH_BEHIND_DAYS).items(NUMBER_of_TWEETS)\r\n\r\n  with open('data.csv', 'a', encoding=&quot;utf8&quot;, newline='' ) as csvfile: \r\n     fieldnames = ['Search', 'URL', 'Tweet', 'Entered on']\r\n     writer = csv.DictWriter(csvfile, fieldnames=fieldnames)\r\n     writer.writeheader()\r\n     \r\n\r\n     for tweet in tweets:\r\n         urls = re.findall('http[s]?:\/\/(?:[a-zA-Z]|[0-9]|[$-_@.&amp;+]|[!*\\(\\),]|(?:%[0-9a-fA-F][0-9a-fA-F]))+', tweet.text)\r\n   \r\n         save_tweet_info(tweet.text, tweet_dict, hashtags_dict ) \r\n         for url in urls:\r\n          try:\r\n            res = urllib2.urlopen(url)\r\n            actual_url = res.geturl()\r\n         \r\n            if ( (&quot;https:\/\/twitter.com&quot; in actual_url) == False):\r\n                \r\n                if len(actual_url) &lt; 32:\r\n                    actual_url =unshortenurl(actual_url) \r\n                print (actual_url)\r\n              \r\n                writer.writerow({'Search': search_term, 'URL': actual_url, 'Tweet': tweet.text, 'Entered on': today_date })\r\n              \r\n          except:\r\n              print (url)    \r\n\r\n            \r\nprint_count_hashtags(hashtags_dict)\r\ncount_urls()      \r\n<\/pre>\n<p><strong>References<\/strong><\/p>\n<p>1. <a href='https:\/\/towardsdatascience.com\/text-mining-twitter-extraction-and-stepwise-guide-to-generate-a-word-cloud-a2c9d626008d' target=\"_blank\">Text mining: Twitter extraction and stepwise guide to generate a word cloud<\/a><br \/>\n2. <a href='https:\/\/www.earthdatascience.org\/courses\/earth-analytics-python\/using-apis-natural-language-processing-twitter\/calculate-tweet-word-frequencies-in-python\/' target=\"_blank\">Analyze Word Frequency Counts Using Twitter Data and Tweepy in Python<\/a><br \/>\n3. <a href='https:\/\/stackoverflow.com\/questions\/53719469\/unshorten-url-in-python-3' target=\"_blank\">unshorten-url-in-python-3<\/a><br \/>\n4. <a href='https:\/\/stackoverflow.com\/questions\/7153096\/how-can-i-un-shorten-a-url-using-python\/7153185#7153185' target=\"_blank\">how-can-i-un-shorten-a-url-using-python<\/a><br \/>\n5. <a href='https:\/\/stackoverflow.com\/questions\/42013072\/extracting-external-links-from-tweets-in-python' target=\"_blank\">extracting-external-links-from-tweets-in-python<\/a><\/p>\n<div class=\"fdcxu69d781163ac30\" ><center>\n<script async src=\"\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js\"><\/script>\n<!-- Text analytics techniques link ads horizontal Medium after content -->\n<ins class=\"adsbygoogle\"\n     style=\"display:inline-block;width:468px;height:15px\"\n     data-ad-client=\"ca-pub-3416618249440971\"\n     data-ad-slot=\"5765984772\"><\/ins>\n<script>\n(adsbygoogle = window.adsbygoogle || []).push({});\n<\/script>\n\n<script async src=\"\/\/pagead2.googlesyndication.com\/pagead\/js\/adsbygoogle.js\"><\/script>\n<ins class=\"adsbygoogle\"\n     style=\"display:block\"\n     data-ad-format=\"autorelaxed\"\n     data-ad-client=\"ca-pub-3416618249440971\"\n     data-ad-slot=\"3903486841\"><\/ins>\n<script>\n     (adsbygoogle = window.adsbygoogle || []).push({});\n<\/script>\n<\/center><\/div><style type=\"text\/css\">\r\n.fdcxu69d781163ac30 {\r\nmargin: 5px; padding: 0px;\r\n}\r\n@media screen and (min-width: 1201px) {\r\n.fdcxu69d781163ac30 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 993px) and (max-width: 1200px) {\r\n.fdcxu69d781163ac30 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 769px) and (max-width: 992px) {\r\n.fdcxu69d781163ac30 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (min-width: 768px) and (max-width: 768px) {\r\n.fdcxu69d781163ac30 {\r\ndisplay: block;\r\n}\r\n}\r\n@media screen and (max-width: 767px) {\r\n.fdcxu69d781163ac30 {\r\ndisplay: block;\r\n}\r\n}\r\n<\/style>\r\n","protected":false},"excerpt":{"rendered":"<p>In this post (and few following posts) we will look how to get interesting information by extracting links from results of Twitter search by keywords and using machine learning text mining. While there many other posts on the same topic, we will cover also additional small steps that are needed to process data. This includes &#8230; <a title=\"Twitter Text Mining\twith Python\" class=\"read-more\" href=\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/\" aria-label=\"More on Twitter Text Mining\twith Python\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0},"categories":[51,61],"tags":[63,20,6,60,64,62],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.4 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Twitter Text Mining with Python - Text Analytics Techniques<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Twitter Text Mining with Python - Text Analytics Techniques\" \/>\n<meta property=\"og:description\" content=\"In this post (and few following posts) we will look how to get interesting information by extracting links from results of Twitter search by keywords and using machine learning text mining. While there many other posts on the same topic, we will cover also additional small steps that are needed to process data. This includes ... Read more\" \/>\n<meta property=\"og:url\" content=\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/\" \/>\n<meta property=\"og:site_name\" content=\"Text Analytics Techniques\" \/>\n<meta property=\"article:published_time\" content=\"2019-05-11T20:13:46+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2019-05-20T00:38:21+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/ai.intelligentonlinetools.com\/ml\/wp-content\/uploads\/2019\/05\/Twitter_API.jpg\" \/>\n<meta name=\"author\" content=\"owygs156\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"owygs156\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/\",\"url\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/\",\"name\":\"Twitter Text Mining with Python - Text Analytics Techniques\",\"isPartOf\":{\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/#website\"},\"datePublished\":\"2019-05-11T20:13:46+00:00\",\"dateModified\":\"2019-05-20T00:38:21+00:00\",\"author\":{\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/#\/schema\/person\/832f10562faaa1c7ed668c1ab4388857\"},\"breadcrumb\":{\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Twitter Text Mining with Python\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/#website\",\"url\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/\",\"name\":\"Text Analytics Techniques\",\"description\":\"Text Analytics Techniques\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/#\/schema\/person\/832f10562faaa1c7ed668c1ab4388857\",\"name\":\"owygs156\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/ai.intelligentonlinetools.com\/ml\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/b351def598609cb4c0b5bca26497c7e5?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/b351def598609cb4c0b5bca26497c7e5?s=96&d=mm&r=g\",\"caption\":\"owygs156\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Twitter Text Mining with Python - Text Analytics Techniques","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/","og_locale":"en_US","og_type":"article","og_title":"Twitter Text Mining with Python - Text Analytics Techniques","og_description":"In this post (and few following posts) we will look how to get interesting information by extracting links from results of Twitter search by keywords and using machine learning text mining. While there many other posts on the same topic, we will cover also additional small steps that are needed to process data. This includes ... Read more","og_url":"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/","og_site_name":"Text Analytics Techniques","article_published_time":"2019-05-11T20:13:46+00:00","article_modified_time":"2019-05-20T00:38:21+00:00","og_image":[{"url":"http:\/\/ai.intelligentonlinetools.com\/ml\/wp-content\/uploads\/2019\/05\/Twitter_API.jpg"}],"author":"owygs156","twitter_card":"summary_large_image","twitter_misc":{"Written by":"owygs156","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/","url":"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/","name":"Twitter Text Mining with Python - Text Analytics Techniques","isPartOf":{"@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/#website"},"datePublished":"2019-05-11T20:13:46+00:00","dateModified":"2019-05-20T00:38:21+00:00","author":{"@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/#\/schema\/person\/832f10562faaa1c7ed668c1ab4388857"},"breadcrumb":{"@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/twitter-text-miningwith-python\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/ai.intelligentonlinetools.com\/ml\/"},{"@type":"ListItem","position":2,"name":"Twitter Text Mining with Python"}]},{"@type":"WebSite","@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/#website","url":"https:\/\/ai.intelligentonlinetools.com\/ml\/","name":"Text Analytics Techniques","description":"Text Analytics Techniques","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/ai.intelligentonlinetools.com\/ml\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/#\/schema\/person\/832f10562faaa1c7ed668c1ab4388857","name":"owygs156","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/ai.intelligentonlinetools.com\/ml\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/b351def598609cb4c0b5bca26497c7e5?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/b351def598609cb4c0b5bca26497c7e5?s=96&d=mm&r=g","caption":"owygs156"}}]}},"_links":{"self":[{"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/posts\/876"}],"collection":[{"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/comments?post=876"}],"version-history":[{"count":19,"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/posts\/876\/revisions"}],"predecessor-version":[{"id":893,"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/posts\/876\/revisions\/893"}],"wp:attachment":[{"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/media?parent=876"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/categories?post=876"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ai.intelligentonlinetools.com\/ml\/wp-json\/wp\/v2\/tags?post=876"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}