Explain Codes LogoExplain Codes Logo

Python

How to Make Inline Plots in Jupyter Notebook Larger?

python
matplotlib
plot-sizing
jupyter-notebook

Python dictionary from an object's fields

python
object-oriented-programming
dataclasses
dictionary

Pyodbc insert into sql

python
database-connection
sql-injection
error-handling

How to delete last item in list?

python
list-manipulation
performance
best-practices

How to pull a random record using Django's ORM?

python
django-orm
custom-managers
random-record-retrieval

How can I avoid "RuntimeError: dictionary changed size during iteration" error?

python
runtimeerror
dictionary-changed-size-during-iteration
python-3

Pythonic way to avoid "if x: return x" statements

python
best-practices
functions
performance

Pandas: Setting the number of maximum rows

python
dataframe
display-options
pandas

How to extract text from a PDF file?

python
pdf-extraction
python-libraries
text-extraction

Apt command line interface-like yes/no input?

python
prompt-engineering
functions
best-practices

Why does "bytes(n)" create a length n byte string instead of converting n to a binary representation?

python
byte-literals
byte-sequences
python-versions

What is an alternative to execfile in Python 3?

python
execfile
python-3
script-execution

How do I trim whitespace?

python
functions
best-practices
dataframe

Apply pandas function to column to create multiple new columns?

python
pandas
dataframe
vectorized-solutions

How to execute multi-line statements within Python's own debugger (PDB)

python
prompt-engineering
debugging
pdb

Error "filename.whl is not a supported wheel on this platform"

python
pip-install
python-versions
wheel-file-handling

Python pandas to_sql with sqlalchemy: how to speed up exporting to MS SQL?

python
to_sql
sqlalchemy
performance

How to change dataframe column names in PySpark?

python
pandas
dataframe
renaming

Which is the preferred way to concatenate a string in Python?

python
string-concatenation
performance
best-practices

Reverse / invert a dictionary mapping

python
dataframe
defaultdict
pythonic