Explore runnable examples for popular Python packages — open any example and run it instantly in your browser.
Use the getpass module to enter a secret at runtime
View example →Use the Pandas library to read a CSV file
View example →Use the Polars library to read a CSV file from a URL
View example →Use the Matplotlib library to create charts.
View example →Use the Seaborn library to create a simple line plot
View example →Use the Plotly library to create a simple line plot
View example →Use the GeoPandas library to load and visualize a map
View example →Use the Treelib library to create a tree of subclasses
View example →Use the Altair library to create an interactive scatter plot
View example →Use the Bokeh library to create a simple scatter plot
View example →How to create a simple Panel app with a slider and a number indicator.
View example →Use the Bokeh library to create a simple app with sliders and a plot
View example →Use the HoloViews and Panel libraries to create an interactive crossfilter plot
View example →Use the Python NetworkX library to create a weighted graph and visualize it using Matplotlib
View example →Use the Folium library to create a choropleth map
View example →Use the Faker library to generate fake data
View example →How to read and write files in Python.
View example →Use the Pillow library to create a simple image
View example →Use the Biopython library to perform a pairwise sequence alignment
View example →Use KNeighborsClassifier from scikit-learn
View example →Solving linear equations with scipy
View example →Array operations with NumPy
View example →Python statsmodels example for performing linear regression
View example →Working with multi-dimensional labeled data using xarray
View example →Parallel computing and large dataset handling using Dask
View example →Basic image processing using OpenCV
View example →Basic image processing using Scikit-Image
View example →Training a regression model using XGBoost
View example →Training a regression model using LightGBM
View example →Using regular expressions to parse log entries and extract structured information
View example →Query a CSV file using DuckDB
View example →Create a and use a SQLite database
View example →Use the sympy library to solve inequalities
View example →Profiling Python code with Pyinstrument
View example →Use the Pygal library to create a stacked bar chart
View example →Use the Python igraph library to create a network graph and visualize it using Matplotlib
View example →How to get user input in Python.
View example →Use the OpenAI Python library to generate LLM responses
View example →Use the Python docx library to create and update Microsoft Word (.docx) files
View example →Use the Python pptx library to create and update Microsoft PowerPoint (.pptx) files
View example →Use the Python xlsxwriter library to create and update Microsoft Excel (.xlsx) files
View example →Use the Python openpyxl library to create and update Microsoft Excel (.xlsx) files
View example →Use the Python pyyaml library to create and update YAML files
View example →Use the Python reportlab library to create PDF files
View example →