WordCloud with Python - Full tutorial with examples

Поделиться
HTML-код
  • Опубликовано: 13 дек 2024

Комментарии • 57

  • @mansi_ax
    @mansi_ax 3 года назад +1

    Thank you for explaining so many variations of wordclouds with examples in a single video!

  • @somebodyelseyoudontknow
    @somebodyelseyoudontknow 2 года назад

    Thank you so much for the easy to follow tutorial

  • @sn4k321
    @sn4k321 3 года назад

    Thanks bro! You exlained with a very simple way!

  • @engitect
    @engitect 4 года назад +2

    Well explained. Subscribed!

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад +1

      Thank you for the comment and for subscribing to the channel!

  • @g2gdude519
    @g2gdude519 4 года назад +1

    Thanks for the excellent python tutorial. Subscribed!

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад

      Thanks for the comment and for the subscription :)

  • @LeicSurvey_videos
    @LeicSurvey_videos Месяц назад

    Hi, Great video and perfect explanation. Please tell me from which source you have downloaded the batman png because i am trying use some png of cloud shapes from google but it is not working. Awaiting for your reply. Thanks

  • @suraiyashahreen1305
    @suraiyashahreen1305 4 года назад

    you deserve many likes istg

  • @alhdlakhfdqw
    @alhdlakhfdqw 3 года назад

    thank you very much for all your great vids Kostadin! :)

  • @nicoloretis6328
    @nicoloretis6328 4 года назад

    Excellent tutorial, seriously

  • @naimuddinsiddiqui9249
    @naimuddinsiddiqui9249 3 года назад +1

    can you please explain syntex for python 3.9.5 ?

  • @mariamitroussi3180
    @mariamitroussi3180 3 года назад

    Thank you for everything. Really interesting and well-explained video.!

  • @maxparsons9431
    @maxparsons9431 Год назад

    I have the word cloud down, but I am attempting to do a list of names and wish for the first and last names to stay by each other even though there is a space, is that possible?

  • @tiffanyw3794
    @tiffanyw3794 6 месяцев назад

    Can we change the font used

  • @jakeg9711
    @jakeg9711 2 года назад

    Is there a way to show both word cloud and bar chart? Thanks

  • @RupamMedhi
    @RupamMedhi 3 года назад +1

    How to make the output image transparent like PNG file?

    • @Pythonenthusiast
      @Pythonenthusiast  3 года назад

      Hi Rupam, I think the link below will help you out:
      github.com/amueller/word_cloud/issues/186
      I guess the only solution is to set the background color to a transparent background. Give it a try and let me know if it worked!

  • @debatradas9268
    @debatradas9268 3 года назад

    thank you so much

  • @Bone51211
    @Bone51211 3 года назад

    Very helpful

  • @jimmyibanez2178
    @jimmyibanez2178 3 года назад

    thanks, the best video

  • @nehasingh7975
    @nehasingh7975 3 года назад

    Thanks!

  • @nishaFly9
    @nishaFly9 4 года назад

    great, i tried to code.. it worked. Thanks Kostadin Ristovski

  • @chetanyasaini3899
    @chetanyasaini3899 2 года назад

    how to install pil lib?

  • @GeekyMino
    @GeekyMino 4 года назад +2

    Great tutorial. Is there a way to make the words appear one after another with some delay? It would be really cool to make an animation like that :)

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад +1

      That is a great question. This library doesn't have that option built-in. It only counts the frequency of the words and then takes a few settings (such as the font size and the number of words) in order to create the plot on a predefined surface.
      The only library known to me at the moment that has some animations is WordSwarm. It plots the words over time creating an animation. The words increase/decrease in size as the time in the animation goes by. Maybe that's worth checking :)

  • @hakunamatata-qu7ft
    @hakunamatata-qu7ft 4 года назад

    Hello bro,how to take text and image from user and generate the image

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад

      Hi Manoj, that is a very good question.
      One of the easiest ways to do that is combining the code in this tutorial and use Tkinter.
      You can create a GUI (graphical user interface) and allow the user to click a button in order to load an image as well as input the text (either from a file or type it in a box).
      Hope this helps!

    • @hakunamatata-qu7ft
      @hakunamatata-qu7ft 4 года назад

      But I am new to this python and programming I felt your videos so helpful so I m taking baby steps,anyways you are of great help ,if I have a question may I reach you if you don't mind

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад +1

      There's no such thing as easy beginning. Keep going and don't give up. Whenever you're stuck, don't forget that most likely Google and Stack Overflow have your answer :) I'm always happy to help.

  • @MegaLobo000
    @MegaLobo000 4 года назад

    Excelente video. disculpa estoy necesitando hacer una lista de nubes de palabras donde tengo como información básica las filas de una tabla. Sabes donde puedo conseguir información. Muchas gracias

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад

      Hi Jesus, thanks for the question (and also for Google translate that helped me translate it). I guess the table has the word and the number of time it repeats. What you can do is, create an empty list, and then loop through your table. It would look something like this:
      empty_list = []
      For i in range(number_of_rows_in_the_table):
      for x in range(times_the_word_is_repeating):
      empty_list.append(the_word)
      If you do this part correctly, your "empty_list" would no longer be empty and would contain all the words.
      Good luck and hope this helps!

  • @ucol2068
    @ucol2068 3 года назад

    Hello bro, I get an error when trying to install word cloud. I use a Mac

    • @Pythonenthusiast
      @Pythonenthusiast  3 года назад +1

      Hey there, have you tried pip install wordcloud?

  • @MeMeHUB-lq2ky
    @MeMeHUB-lq2ky 4 года назад

    Can I change font?

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад

      Hi there! Yes, you can also change font. Check the documentation part:
      amueller.github.io/word_cloud/generated/wordcloud.WordCloud.html?highlight=font
      You need to add the font_path accordingly.

  • @naimuddinsiddiqui9249
    @naimuddinsiddiqui9249 3 года назад

    thanks a billons

  • @salikmalik7631
    @salikmalik7631 4 года назад +1

    can you make make a videos on numpy...

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад

      Hey Salik, Thanks for the comment. Absolutely, it is on my list :)

    • @salikmalik7631
      @salikmalik7631 4 года назад

      @@Pythonenthusiast Thanks for reply. The way demonstrate is awesome.
      That's why I asked for numpy. I want it.

  • @priyanshkulshrestha799
    @priyanshkulshrestha799 4 года назад

    its not working on my mask images.

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад

      Well, in the tutorial I've mentioned the possible reason when it won't work. It could be that your mask is not good enough for this purpose.

  • @MrKelvinks
    @MrKelvinks 4 года назад

    what if I want the words to appear as phrases? for example - I love to hug, Happy Birthday, really cool guy. How can you accomplish that?

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад

      Hello there!
      The purpose of this library is to fill a given shape using the most-frequently used words.
      I don't fully understand the question as there are 2 scenarios:
      1. You want phrases to appear, not only words. In that case, you need to have the phrase as an element that will be used to fill the shape.
      2. You want the shape of the wordcloud to be a phrase. In that case, you need an image of the phrase that you'll use as a shape that is to be filled.
      Hope this helps!

    • @MrKelvinks
      @MrKelvinks 4 года назад

      @@Pythonenthusiast what i meant is rather than pick up single words, can it pick up more than one word as a block...so instead of just picking up "good", it picks up " he is good", so in the word cloud what you see is he is good, rather than just good...if that makes sense..

    • @Pythonenthusiast
      @Pythonenthusiast  4 года назад +2

      ​@@MrKelvinks Think from the library's point of view. What it does is it takes words and builds a cloud. The more times a word shows, the larger it is in size. Now, let's say that you have phrases, stored in a list, such as:
      ['He is kind', 'He is kind', 'He is good', 'He is smart', 'He has 5 dogs', 'He is kind'] etc.
      This should work as you have phrases and frequency. Note that you need lots of phrases in order to build a wordcloud in a particular shape and you need the phrases to repeat different amount of times for the size.
      However, if you have a piece of text and let's say that the following sentence is part of it:
      "He is kind, smart and has 5 dogs.".
      The library would not separate "He is kind" only. The only way you can use text is to separate by dot, meaning separate each sentence separately.
      However, then you'll have all sentences as part of the cloud, unless you manually select the phrases, which goes back to the first example in this comment.
      Note that there is a reason why this library is called "WordCloud" :)
      Hope this helps!

  • @fiqoanugrah9884
    @fiqoanugrah9884 3 года назад

    mana anak pacil

  • @Username44566
    @Username44566 3 года назад

    Thanks!