List 如何合并文件中的多个列表

List 如何合并文件中的多个列表,list,twitter,merge,semantics,tweepy,List,Twitter,Merge,Semantics,Tweepy,我创建了以下代码来对tweet进行精液分析。文本从csv文件中的单个列加载。我唯一无法解决的问题是,它会创建多个列表。如何将这些列表合并为一个列表 for tweet in tweets_list: lower = tweet.lower() #print(lower) convert = re.sub('((www\.[^\s]+)|(https?://[^\s]+))','URL',lower) #print(convert) whitespace =

我创建了以下代码来对tweet进行精液分析。文本从csv文件中的单个列加载。我唯一无法解决的问题是,它会创建多个列表。如何将这些列表合并为一个列表

for tweet in tweets_list:
    lower = tweet.lower()
    #print(lower)
    convert = re.sub('((www\.[^\s]+)|(https?://[^\s]+))','URL',lower)
    #print(convert)
    whitespace = re.sub('[\s]+', ' ', convert)
    #print(whitespace)
    hashtagmin = re.sub(r'#([^\s]+)', r'\1', whitespace)
    #print(hashtagmin)
    tweettrim = hashtagmin.strip('-_),(:@;.?\'"')
    #print(tweettrim)
    wordslist = tweettrim.split(' ')
    print(wordslist)
输出类似:(列表不在括号中..)

['tweet', 'content']
['please', 'rt!', '1st', 'vgk', 'game', 'ever', 'at', 't-mobile', 'arena', 'and', 'more', 'than', '50%', 'of', 'vegas', 'can', 'not', 'watch', 'on', 'tv.', 'send', 'a', 'message', 'to', '@coxcomm,', 'end', 'coxblocked!']
['t-mobile', 'offer', 'was', 'only', 'for', 'subscribers', '']
['but', 'for', 'jlk', 'n', 'spyder', '']
['bogo,', 'fandango', ',', 'at', '&', 't', 'offers', '']
['still', 'unbeaté', 'URL']
['t-mobile', 'offer', 'ani', 'edisinantha', 'easy', 'kadu', 'ra', 'premiers', "record's", 'kottadam', 'ante']
['bacha', 'gallatho', 'boss', 'ki', 'comparison', 'okatié', 'URL']
['cody', 'eakin', 'scores', 'the', 'first', 'vegas', 'goal', 'in', 't-mobile', 'arena', 'history.', 'first', 'goal', 'ever', 'in', 'the', 'building', 'was', 'scored', 'by', 'michael', 'mersch.', '1-0', 'vgk,', '1p']
['video:', 'cody', 'eakin', 'scores', 'the', 'golden', "knights'", 'first-ever', 'goal', 'at', 't-mobile', 'arena.', 'URL', 'URL']
['after', 'puerto', 'rico', 'hurricanes,', 'at&t', 'and', 't-mobile', 'provide', 'sms', 'queue', 'services', 'URL']
['cody', 'eakin', 'gets', 'the', 'first', 'golden', 'knights', 'goal', 'at', 't-mobile', 'arena', 'vegasgoldenknights', 'URL']
['t-mobile', 'offer', 'was', 'only', 'for', 'subscribers', '']