[Python] Word Clouds using TabPy

Discussão em 'Python' iniciado por Stack, Julho 17, 2025.

  1. Stack

    Stack Membro Participativo

    I want to create some code in TabPy that will count the frequency of words in a column and remove stop words for a word cloud in Tableau.

    I'm able to do this easily enough in Python:

    other1_count = other1.answer.str.split(expand=True).stack().value_counts()
    other1_count = other1_count.to_frame().reset_index()
    other1_count.columns = ['Word', 'Count']

    ### Remove stopwords
    other1_count['Word'] = other1_count['Word'].apply(lambda x: ' '.join([word for word in x.split() if word not in (stop)]))
    other1_count['Word'].replace('', np.nan, inplace=True)
    other1_count.dropna(subset=['Word'], inplace=True)
    other1_count = other1_count[~other1_count.Word.str.contains("nan")]


    But less sure how to run this through TabPy. Anyone familiar with TabPy and how I can make this run?

    Thanks in advance.

    Continue reading...

Compartilhe esta Página