Bag of Words 란 단어들의 출현 빈도를 수치화한 표현 방법. def BoW(sentences): dict_bow = {} for sentence in sentences: split_sentence = sentence.split(" ") for word in split_sentence: if word not in dict_bow.keys(): dict_bow[word] = 1 else: dict_bow[word] = dict_bow[word] + 1 return dict_bow sentences = [ "빨간 사과 노란 바나나 초록 메론", "주황 오렌지 노란 바나나 빨간 자두" ] print(BoW(sentences)) #{'빨간': 2, '사과': 1, '노란': 2, '바나나': 2, '초록..