Polars - An Introduction to Polars v1 for Python Data Analytics!

แชร์
ฝัง
  • เผยแพร่เมื่อ 25 ก.ค. 2024
  • ☕️ 𝗕𝘂𝘆 𝗺𝗲 𝗮 𝗰𝗼𝗳𝗳𝗲𝗲:
    To support the channel and encourage new videos, please consider buying me a coffee here:
    ko-fi.com/bugbytes
    In this video we'll introduce the Polars package for data analytics in Python. This is a modern, rapidly growing alternative to Pandas for data analysis.
    We'll look at the core data structures (Series, DataFrames) and will look at how to select rows/columns, add new columns, drop columns, aggregate and sort data, handle null values, plot data to charts, and how to read/write data from/to files.
    📌 𝗖𝗵𝗮𝗽𝘁𝗲𝗿𝘀:
    00:00 Intro
    00:26 Introduction to Polars
    01:12 Installing Polars
    02:14 Series objects in Polars
    04:26 DataFrame objects in Polars
    07:08 Selecting columns from DataFrames
    08:53 Selecting rows with DataFrame filter method
    11:05 Adding and Dropping columns from DataFrames
    13:59 Sorting DataFrames
    15:02 Grouping and Aggregation with DataFrames
    19:17 Handling null values with Polars
    24:00 Serialising data to files with Polars
    25:33 Plotting DataFrame data with Polars
    28:33 Polars and Pandas comparison
    𝗦𝗼𝗰𝗶𝗮𝗹 𝗠𝗲𝗱𝗶𝗮:
    📖 Blog: bugbytes.io/posts/
    👾 Github: github.com/bugbytes-io/
    🐦 Twitter: / bugbytesio
    📚 𝗙𝘂𝗿𝘁𝗵𝗲𝗿 𝗿𝗲𝗮𝗱𝗶𝗻𝗴 𝗮𝗻𝗱 𝗶𝗻𝗳𝗼𝗿𝗺𝗮𝘁𝗶𝗼𝗻:
    Polars: docs.pola.rs/
    Comparison with Pandas: docs.pola.rs/user-guide/migra...
    #python #polars #datascience #data

ความคิดเห็น • 37

  • @RajaseelanGaneswaran
    @RajaseelanGaneswaran 12 วันที่ผ่านมา +2

    Love this video. great intro!

  • @ringpolitiet
    @ringpolitiet 19 วันที่ผ่านมา +4

    Thanks for the video. A polars/pandas/duckdb video would be lovely. Would also be nice if you could then showcase the lazy evaluation/query optimizer in polars compared to pandas. And if you're talking about duckdb which is SQL adjacent, maybe also some words about the SQL interface in polars.

    • @bugbytes3923
      @bugbytes3923  17 วันที่ผ่านมา +1

      Great suggestions, thank you - I'll look into some follow-up videos, including the polars/pandas/duckdb comparison.

  • @jamesinaz8042
    @jamesinaz8042 20 วันที่ผ่านมา +1

    Awesome 💯 will try it out soon

    • @bugbytes3923
      @bugbytes3923  20 วันที่ผ่านมา +1

      Thanks a lot, and good luck!

  • @Pradeep_prasad
    @Pradeep_prasad 20 วันที่ผ่านมา +1

    Thank you for introducing new library❤

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา +1

      @@Pradeep_prasad no problem thanks for watching!

  • @md.musfiqurrahaman8612
    @md.musfiqurrahaman8612 20 วันที่ผ่านมา +1

    Subscribed ! For amazing contents and consistency! Keep it up!♥

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา

      @@md.musfiqurrahaman8612 thanks a lot, much appreciated!

  • @michaelmaguire6709
    @michaelmaguire6709 20 วันที่ผ่านมา +1

    Perfect!

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา

      @@michaelmaguire6709 thanks!

  • @knolljo
    @knolljo 20 วันที่ผ่านมา +2

    polars is super nice to work with, did some data analysis in the last few months. Combined with marimo notebooks it felt like super powers 😅

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา

      @@knolljo I’ll need to check out marimo notebooks!

    • @knolljo
      @knolljo 19 วันที่ผ่านมา

      @@bugbytes3923 Definitely worth it! The ability to have reactive and easy to use interactive elements makes it amazing to work with, plus the notebooks are saved as .py files and can even be exported as standalone scripts, I love that as a git user.

  • @smellypunks
    @smellypunks 6 วันที่ผ่านมา

    I have been using pandas for years and was waiting to switch to polars which I started to do this year. Lots of pandas scripts to migrate!! I do enjoy Polars even small things like showing strings in “” helps. But some methods seem more verbose than needed and there are some conversations that seem to have been changed unnecessarily. On Nulls very happy to move always from Pandas hellish null handling.

  • @Mshiunwu
    @Mshiunwu 17 วันที่ผ่านมา +1

    Thanks for your sharing. I've been a heavy R user for the last ten years. I think Polars is closer to dplyr than Pandas. Now I know a better way to migrate my previous code.

    • @bugbytes3923
      @bugbytes3923  16 วันที่ผ่านมา

      @@Mshiunwu thanks for the comment! Glad to hear that Polars is more similar to R - should be easier to pick up for anyone moving to Python!

  • @serychristianrenaud
    @serychristianrenaud 20 วันที่ผ่านมา +1

    Thanks ...🎉

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา

      @@serychristianrenaud thanks for watching!

  • @suyashdahale4355
    @suyashdahale4355 20 วันที่ผ่านมา +2

    Best polars tutorial so far 👍

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา

      @@suyashdahale4355 thanks a lot!

  • @frameff9073
    @frameff9073 20 วันที่ผ่านมา

    🎉🎉🎉

    • @bugbytes3923
      @bugbytes3923  17 วันที่ผ่านมา

      Thanks a lot!!

  • @tmb8807
    @tmb8807 12 วันที่ผ่านมา

    Been using Polars for about a year, and I can't see myself using pandas again. Way faster at basically everything, and even though the code can end up looking quite verbose the syntax comes much more naturally to me. Lacking a built-in plot method was the only snag, but it has that now.
    And as you said, I'm sure there are some integrations with other libraries that might not work, but there's always the to_pandas method.

    • @bugbytes3923
      @bugbytes3923  8 วันที่ผ่านมา +1

      Exactly how I feel too! I'll probably not go back to Pandas much, unless required, although it's served me well for a long time.

    • @tmb8807
      @tmb8807 8 วันที่ผ่านมา

      @@bugbytes3923Indeed. Pandas is still very ingrained (understandably so) so it’ll probably take time for things to move generally. But I’m excited about the possibilities. I’ve even seen it demonstrated that, due to the streaming API allowing it to process larger-than-memory data, Polars is capable of replacing Spark on a single node for some workflows (not all, of course).

  • @ahmedbadal3795
    @ahmedbadal3795 20 วันที่ผ่านมา +1

    am at 15:00 enjoying it so far what a great tutorial thanks for it why does polars seem better then pandas

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา

      @@ahmedbadal3795 thanks a lot!

  • @lhassanaitmouss389
    @lhassanaitmouss389 18 วันที่ผ่านมา

    Thanks 🎉
    (select, filter, with_columns, groupBy, …) seems like Spark 😅

    • @bugbytes3923
      @bugbytes3923  17 วันที่ผ่านมา

      True! Some similarities with PySpark!

  • @yasithawijethunga5742
    @yasithawijethunga5742 19 วันที่ผ่านมา

    Can't use htmx and jquery together for a dropdown in django? I added a htmx get request to a dropdown. But when I use jquery select2 plugin for the dropdown, htmx get not working

  • @patcher2944
    @patcher2944 19 วันที่ผ่านมา

    What is i64 means below age

    • @bugbytes3923
      @bugbytes3923  19 วันที่ผ่านมา

      @@patcher2944 int64 (integer)

  • @NoName-lq7kt
    @NoName-lq7kt 20 วันที่ผ่านมา

    Looks really cool too bad I'll never get a tech job

    • @ringpolitiet
      @ringpolitiet 19 วันที่ผ่านมา

      That's the spirit.

  • @alexandrodisla6285
    @alexandrodisla6285 20 วันที่ผ่านมา

    I know Polars.