<jupyter_start><jupyter_text>Save Data<jupyter_code>os.makedirs("data/list_apps/", exist_ok=True)
app_infos_df.to_csv('data/list_apps/info_apps.csv', index = None, header=True)<jupyter_output><empty_output><jupyter_text>Get App Reviews<jupyter_code># no modification
app_reviews = []

for ap in tqdm(app_packages):
    for score in list(range(1, 6)):
        for sort_order in [Sort.MOST_RELEVANT, Sort.NEWEST]:
            rvs, _ = reviews(
                ap,
                lang='id',
                country='id',
                sort=sort_order,
                count= 300 if score == 3 else 200,
                filter_score_with=score
              )
            
            for r in rvs:
                r['sortOrder'] = 'most_relevant' if sort_order == Sort.MOST_RELEVANT else 'newest'
                r['appId'] = ap
            app_reviews.extend(rvs)<jupyter_output><empty_output><jupyter_text>app_reviews = []for ap in tqdm(app_packages):    for score in list(range(1, 6)):        for sort_order in [Sort.MOST_RELEVANT, Sort.RATING, Sort.NEWEST]:            rvs, _ = reviews(                ap,                lang='id',                country='id',                sort=sort_order,                count= 300 if score == 3 else 200,                filter_score_with=score              )                        for r in rvs:                r['sortOrder'] = 'most_relevant' if sort_order == Sort.MOST_RELEVANT else 'rating' if sort_order == Sort.RATING else 'newest'                r['appId'] = ap            app_reviews.extend(rvs) print_json(app_reviews[1]) app_reviews_df = pd.DataFrame(app_reviews)app_reviews_df.shape app_reviews_df.head()<jupyter_code># just try

app_reviews_df.to_csv('data/review_apps/apps_review_join.csv', index = None, header=True)<jupyter_output><empty_output><jupyter_text>Filter column values<jupyter_code># Filter column values
appdf_most_relevant = app_reviews_df[app_reviews_df.sortOrder.isin(["most_relevant"])]
appdf_most_relevant.head()
appdf_most_relevant.shape<jupyter_output><empty_output><jupyter_text>check filter each keyword<jupyter_code>appdf_tiktok = app_reviews_df[app_reviews_df.appId.isin(["com.ss.android.ugc.trill"])]
appdf_tiktok.head()
appdf_ome = app_reviews_df[app_reviews_df.appId.isin(["omegle.tv"])]
appdf_ome.head()
appdf_ome.shape<jupyter_output><empty_output><jupyter_text>save to file csv<jupyter_code>os.makedirs("data/review_apps/", exist_ok=True)
appdf_ome.to_csv('data/review_apps/apps_review_ome.csv', index = None, header=True)
appdf_tiktok.to_csv('data/review_apps/apps_review_tiktok-nonrating.csv', index = None, header=True)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.11604095563139932, 'fraction_numerical': 0.00720515737580584, 'mean_word_length': 3.3034257748776508, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '6', 'dir': 'jupyter-structured-clean-dedup', 'id': '190120', 'license': 'MIT', 'n_tokens_mistral': 961, 'n_tokens_neox': 907, 'n_words': 142, 'path': 'crawling_data.ipynb', 'repo_name': 'nikenaml/google-play-apps-reviews', 'size': '2637'}